peeking into stdin/stdout buffers?
Tim Drury
tim.drury@gtri.gatech.edu
Mon May 4 07:02:00 GMT 1998
Can you peek into the stdin/stdout buffers using ANSI C? ftell() and fgetpos()
don't work, but I really can't see why they wouldn't. I've dumped the __sFILE
structure for each, but none of the elements change.
Is there a non-ANSI C way of doing it?
All I want to do is see if any characters have been received before calling
fread(). I don't want fread() to hang the CPU while waiting for characters.
-tim
More information about the crossgcc
mailing list