Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP
Posting-Version: version B 2.10.1 6/24/83; site utah-cs.UUCP
Path: utzoo!watmath!clyde!cbosgd!ihnp4!zehntel!hplabs!utah-cs!lepreau
From: lepreau@utah-cs.UUCP (Jay Lepreau)
Newsgroups: net.unix-wizards
Subject: Re: 4.2bsd eof flag in stdio
Message-ID: <3130@utah-cs.UUCP>
Date: Sun, 2-Dec-84 00:54:57 EST
Article-I.D.: utah-cs.3130
Posted: Sun Dec  2 00:54:57 1984
Date-Received: Tue, 4-Dec-84 07:38:59 EST
References: <127@ISM780B.UUCP>
Organization: Univ of Utah CS Dept
Lines: 27

Jim@ISM780B states in two separate articles:
> show me the manual page for fread that says that 0 is returned upon EOF! 
> ...
> When discussing fine points of documentation, it is more accurate and less
> embarrassing to use your eyeballs, not your memory....
> you should not be so arrogant as to assume that you are not subject to
> such misconceptions without verifying it.
> ...
> NOWHERE DOES IT SAY THAT FREAD RETURNS ZERO UPON END-OF-FILE.

Taking Jim's own humble advice on the use of eyeballs and arrogance
I found in the v7 manual under fread(3):
	DIAGNOSTICS
		Fread and fwrite return 0 upon end of file or error.
And so does the 4.2 manual, which is derived from 32v which is derived
from v7.  Now, in Sys V (and Sys 3?), rather than change the code to
fix a bug they changed the documentation and removed that sentence.
Sun and UCB chose to fix the code.  Fine.  Arguments can be made both
ways.  (Of course I have strong opinions as to which is preferable.)

However, the so-called issue of whether or not ^D other than at the
beginning of a line should mean EOF is a straw man, and is not at issue
(or shouldn't be, anyway).  In any case it is orthogonal to the issue of
sticky-eof on ttys, and is just muddying the waters.  It's about as
germane and likely to change as adding ^^ or BCD to C.

Jay Lepreau