This is not mingw-w64 related stuff. I suggest you ask it in the correct ML next time.
ISO C++ N3936 § 27.7.2.3 Unformatted input functions pos_type tellg(); 40 Returns: After constructing a sentry object, if fail() != false, returns pos_type(-1) to indicate failure. Otherwise, returns rdbuf()->pubseekoff(0, cur, in). It's highly probable that you are using eof() in a WRONG way. So provide a minimal testcase please. ------------------ Best regards, lh_mouse 2014-12-06 ------------------------------------------------------------- 发件人:Jim Michaels <[email protected]> 发送日期:2014-12-06 06:56 收件人:mingw64 users 抄送: 主题:[Mingw-w64-public] bug in ftream RE: .tellg() and .seekg() the code I have is large. what is does is open a text filesave the position from .tellg() read through a file using .getline() until it hits .eof() and then it does an i.seekg() to the saved position (which I found out originally was 0).but apparently after the seekg, itellg reports -1. this is wrong. something got messed up after hitting eof. I should be able to rewind the file, shouldn't i? ------------- Jim Michaels [email protected] [email protected] http://RenewalComputerServices.com http://JesusnJim.com (computer repair info, programming) ------------------------------------------------------------------------------ Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server from Actuate! Instantly Supercharge Your Business Reports and Dashboards with Interactivity, Sharing, Native Excel Exports, App Integration & more Get technology previously reserved for billion-dollar corporations, FREE http://pubads.g.doubleclick.net/gampad/clk?id=164703151&iu=/4140/ostg.clktrk _______________________________________________ Mingw-w64-public mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/mingw-w64-public ------------------------------------------------------------------------------ Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server from Actuate! Instantly Supercharge Your Business Reports and Dashboards with Interactivity, Sharing, Native Excel Exports, App Integration & more Get technology previously reserved for billion-dollar corporations, FREE http://pubads.g.doubleclick.net/gampad/clk?id=164703151&iu=/4140/ostg.clktrk _______________________________________________ Mingw-w64-public mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/mingw-w64-public
