Path: utzoo!mnetor!uunet!sdrc!scjones From: scjones@sdrc.UUCP (Larry Jones) Newsgroups: comp.lang.c Subject: Re: Binary I/O on stdin/stdout? Message-ID: <253@sdrc.UUCP> Date: 3 Apr 88 00:35:33 GMT References: <302@goofy.megatest.UUCP> <225800017@uxe.cso.uiuc.edu> <3295@haddock.ISC.COM> Organization: Structural Dynamics Research Corp., Cincinnati Lines: 24 In article <3295@haddock.ISC.COM>, karl@haddock.ISC.COM (Karl Heuer) writes: > In article <2500@bsu-cs.UUCP> dhesi@bsu-cs.UUCP (Rahul Dhesi) writes: > >[In VMS] the default type of a file opened from a C program is stream-LF, > >which uses records terminated by linefeeds, and does not distinguish between > >text and binary formats at all, acting like UNIX and POSIX files. > > The fact that it's called "stream-LF" (as distinct from "stream-CR" or just > "stream") suggests that the newlines which terminate the records have some > significance to the OS. Is it legal, for example, to write 70000 characters > without a newline? If not, this doesn't seem like an acceptable format for > binary mode. Yes, you can write as many characters as you want without a newline - you don't even need one at the end of the file. The only significance of the "stream-LF" designation is to allow the file system to simulate a record structured file meaningfully. Since most VMS programs are only capable of handling record structure files (stream file being relatively new), this is of immeasurable value. ---- Larry Jones UUCP: uunet!sdrc!scjones SDRC MAIL: 2000 Eastman Dr., Milford, OH 45150 AT&T: (513) 576-2070 "When all else fails, read the directions."