Date: Fri, 26 Jun 2020 15:39:51 +1000 (AEST) From: Damian McGuckin <damianm@....com.au> To: musl@...ts.openwall.com Subject: Re: errno not set to EBADF when reading from invalid descriptor On Fri, 26 Jun 2020, Markus Wichmann wrote: > So I can't actually use a FILE open for reading and writing that refers > to something non-seekable, like a serial line, to both read and write to > it? Certainly STDIO allows this, but you need to be very careful. about doing it. Years ago, I would send a string down a serial line opened Read/Write, as an atomic write, and then immediately, sit on the line waiting for a reply on the same serial line. I was simply trying to retreive the Postscript handshake between the system and the printer which was a very small number of characters. Doing it with 2 FILEs is much smarter for the general case. Regards - Damian Pacific Engineering Systems International, 277-279 Broadway, Glebe NSW 2037 Ph:+61-2-8571-0847 .. Fx:+61-2-9692-9623 | unsolicited email not wanted here Views & opinions here are mine and not those of any past or present employer
Powered by blists - more mailing lists
Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.