diff options
author | Russell Lang <gsview@ghostgum.com.au> | 2001-04-06 08:43:29 +0000 |
---|---|---|
committer | Russell Lang <gsview@ghostgum.com.au> | 2001-04-06 08:43:29 +0000 |
commit | 463a2fb99639068861bd2237ff727c017c0e383b (patch) | |
tree | 82c4f126337bc24e8003ba4b02471c18585a4451 | |
parent | 073f2c86b91ee94724333b671b3bb195141e3a35 (diff) | |
download | ghostpdl-463a2fb99639068861bd2237ff727c017c0e383b.tar.gz |
Fix: Do not put Windows stdin into binary mode if it is the console
because this returns CR and LF each time the Enter key is pressed.
This caused Ghostscript to not pause at following showpage prompts.
git-svn-id: http://svn.ghostscript.com/ghostscript/trunk@1382 a1074d23-0009-0410-80fe-cf8c14f379e6
-rw-r--r-- | gs/src/dwmainc.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/gs/src/dwmainc.c b/gs/src/dwmainc.c index c5e166542..d0ab84954 100644 --- a/gs/src/dwmainc.c +++ b/gs/src/dwmainc.c @@ -313,7 +313,8 @@ int main(int argc, char *argv[]) char buf[256]; char dformat[64]; - _setmode(fileno(stdin), _O_BINARY); + if (!_isatty(fileno(stdin))) + _setmode(fileno(stdin), _O_BINARY); _setmode(fileno(stdout), _O_BINARY); _setmode(fileno(stderr), _O_BINARY); |