Mail Archives: cygwin/1996/11/06/17:24:41
Jeremy Blackman wrote:
>
> Is there a way to set stdin and stdout into binary mode under gnu-win32,
> cleanly? Some code I am attempting to port simply does an
> fdopen(0,"rb"); fdopen(1,"wb"); which works fine under Linux, or BSD,
> but ends up with no output when compiled with gnu-win32 and then run.
>
> Suggestions? I've tried several hacks around this already. The code
> requires that stdout and stdin be in binary mode and also be actually
> stdout and stdin - the program runs as a cgi script.
_setmode(fileno(stdin), O_BINARY);
_setmode(fileno(stdout), O_BINARY);
--
<J Q B>
-
For help on using this list, send a message to
"gnu-win32-request AT cygnus DOT com" with one line of text: "help".
- Raw text -