Read and write /dev/ttya?
klaus u schallhorn
klaus at cnix.uucp
Thu Jan 24 22:08:33 AEST 1991
In article <3971 at stl.stc.co.uk> "Andrew G. Minter" <agm at stl.stc.co.uk> writes:
>In the referenced article veit at du9ds3.uni-duisburg.de (Holger Veit) writes:
>>montnaro at spyder.crd.ge.com (Skip Montanaro) writes:
>>>The getc() just hangs. What am I doing wrong?
>>stdio does input and output buffering. If your answering device does not
>>deliver a Carriage return as a block limiter, your getc() call will wait
>>forever. Try including
>> setbuf(f,NULL);
>
Unless you set ICANON off it's going to wait until it receives
a linefeed. Have a look in termio(4).
klaus
--
George Orwell was an Optimist
More information about the Comp.unix.programmer
mailing list