bug-gnulib
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: mingw lseek bug


From: Eric Blake
Subject: Re: mingw lseek bug
Date: Mon, 28 May 2007 09:03:29 -0600
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.0.10) Gecko/20070221 Thunderbird/1.5.0.10 Mnenhy/0.7.5.666

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

According to Bruno Haible on 5/28/2007 7:55 AM:
> Thanks for explaining. I thought you were talking about the lseek call
> inside fflush, not about an lseek call before it.
> 
> Since loss of data is a severe condition, I'm adding a note about it:

Thanks.

> +     output and seekable input streams are supported.
> +     Note! LOSS OF DATA can occur if fflush is applied on an input stream
> +     that is _not_seekable_ or on an update stream that is _not_seekable_
> +     and in which the most recent operation was input.  Seekability can
> +     be tested with lseek(fileno(fp),0,SEEK_CUR).  */

Do we want to offer ftello(fp) as the shorter alternative to
lseek(fileno(fp),0,SEEK_CUR) for testing seekability?  Furthermore, it
would allow a user application to get by with only <stdio.h> instead of
also needing <unistd.h>.

- --
Don't work too hard, make some time for fun as well!

Eric Blake             address@hidden
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (Cygwin)
Comment: Public key at home.comcast.net/~ericblake/eblake.gpg
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFGWu9B84KuGfSFAYARAmxCAJ0bJWdDUa1DrBLpDN5rV7hE+9JCFACfSix0
Nx0Vea5YykytNZtqeJCP3HQ=
=E7EP
-----END PGP SIGNATURE-----




reply via email to

[Prev in Thread] Current Thread [Next in Thread]