This is the mail archive of the cygwin@sourceware.cygnus.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: B19.1 ftell(), fseek() bug


> Date:          Thu, 14 May 1998 09:59:36 +0200
> From:          "Carsten Roedel K8/DIC2 Tel. 4276" <Carsten.Roedel@rt.bosch.de>

> I discovered a problem with ftell() and fseek() in cygwin32-B19.1 under Win95.
> The problem is, when passing the position got from ftell() to fseek(),
> it does not end up at the same location!? Apparantly ftell does account
> the <cr>/<lf> in the byte stream, where fseek does NOT! It seems that
> fseek skips the <cr> bytes. I think that the ftell behaviour is correct,
> it should always tell the correct position in any byte stream, as it does.
> But, however, it is obvious that ftell and fseek must match together to
> be compatible. 

I remember the same behaviour from an old turboc.
My sollution was to write my own myfseek().

-
For help on using this list (especially unsubscribing), send a message to
"gnu-win32-request@cygnus.com" with one line of text: "help".


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]