Path: utzoo!utgpu!water!watmath!clyde!rutgers!uwvax!oddjob!mimsy!chris From: chris@mimsy.UUCP (Chris Torek) Newsgroups: comp.lang.c Subject: Re: Binary I/O on stdin/stdout? Message-ID: <10820@mimsy.UUCP> Date: 27 Mar 88 15:44:40 GMT References: <302@goofy.megatest.UUCP> <225800017@uxe.cso.uiuc.edu> <4250@hoptoad.uucp> Organization: U of Maryland, Dept. of Computer Science, Coll. Pk., MD 20742 Lines: 22 In article <4250@hoptoad.uucp> gnu@hoptoad.uucp (John Gilmore) writes: > * There seems to be *no way* to "reopen" [stdin and stdout] as >binary. I believe this is the case. I thought at one point that freopen((char *)NULL, "rb", stdin); was supposed to do that sort of thing, but apparently that was just a proposal; it never made it into any draft. (This seems to me a not unreasonable way to do it. Systems that do not have modes need only say if (name == NULL && stream_is_open(stream)) return (stream); while those that do can do whatever is required at system startup and file open time to figure out what modes are permissible and to retain whatever state is needed to set them. -- In-Real-Life: Chris Torek, Univ of MD Comp Sci Dept (+1 301 454 7163) Domain: chris@mimsy.umd.edu Path: uunet!mimsy!chris