Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 16 Nov 1996 21:15:25 -0700
From:      Warner Losh <imp@village.org>
To:        joerg_wunsch@uriah.heep.sax.de (Joerg Wunsch)
Cc:        bde@zeta.org.au (Bruce Evans), cvs-all@freefall.freebsd.org, CVS-committers@freefall.freebsd.org, cvs-usrbin@freefall.freebsd.org, joerg@freefall.freebsd.org
Subject:   Re: cvs commit: src/usr.bin/sed main.c 
Message-ID:  <E0vOydh-0001ZR-00@rover.village.org>
In-Reply-To: Your message of "Sun, 17 Nov 1996 03:50:18 %2B0100." <199611170250.DAA09732@uriah.heep.sax.de> 
References:  <199611170250.DAA09732@uriah.heep.sax.de>  

next in thread | previous in thread | raw e-mail | index | archive | help
In message <199611170250.DAA09732@uriah.heep.sax.de> J Wunsch writes:
: As Bruce Evans wrote:
: > Erm, as I told the submitter, this introduces C programmer's bug
: > #<a bit larger than 1>: feof() is not valid until EOF has been read.
: 
: Huh?  I can't find any reference claiming this.

feof is true as soon as the file gets to the end of the file.  You
needn't read the EOF for feof() to be true.  In Pascal, that was the
case, but not in C...

Warner



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?E0vOydh-0001ZR-00>