🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: gnu.g++.lib.bug
Article #318

Bug in fstream->eof()?

#318
From: Samir Mawa SOW
Date: Mon, 09 Nov 1992 14:11
18 lines
1141 bytes
hi,

I am a new user of your g++ lib (2.2) and I think that something is wrong with the eof method of the fstream-class.

I attempt to use it in a search-program, which uses a ifstream object, but the returned value of eof() is always 0 even on an empty file.


Before writing this mail, I have made several tests
	- I've replaced the eof() method by the fail() method and the program ran
	  properly.
	- I've replaced the g++ library with the DEC c++ lib and the program ran
	  properly

So it seems that the bug comes from the eof() method. Is this a known bug? And if so, is there already a fix for it?

Thanks for your cooperation.

sincerly.    Samir Sow
Technical Details
Message-ID: <9211091411.AA10432@saturnus.telesys-innov.fr>
Path: arc1-ca.pugleaf.net!sparky!uunet!stanford.edu!ames!saimiri.primate.wisc.edu!zaphod.mps.ohio-state.edu!cis.ohio-state.edu!telesys-innov.FR!sms

Show Full Headers
Complete Article Headers
Newsgroups: gnu.g++.lib.bug
Path: arc1-ca.pugleaf.net!sparky!uunet!stanford.edu!ames!saimiri.primate.wisc.edu!zaphod.mps.ohio-state.edu!cis.ohio-state.edu!telesys-innov.FR!sms
From: sms@telesys-innov.FR (Samir Mawa SOW)
Subject: Bug in fstream->eof()?
Message-ID: <9211091411.AA10432@saturnus.telesys-innov.fr>
Sender: gnulists@ai.mit.edu
Organization: GNUs Not Usenet
Distribution: gnu
Date: Mon, 9 Nov 1992 14:11:30 GMT
Approved: bug-lib-g++@prep.ai.mit.edu
Lines: 19