[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Possible bug in fseek/fseeko/lseek modules on MinGW
From: |
Bruno Haible |
Subject: |
Re: Possible bug in fseek/fseeko/lseek modules on MinGW |
Date: |
Sat, 7 Mar 2009 13:51:42 +0100 |
User-agent: |
KMail/1.9.9 |
Hello Martin,
> a user reported a bug in the MinGW version of mpop. After narrowing the
> problem down, it seems that after 'fseek(f, 0, SEEK_SET)' is called for
> a file 'f' that was opened in mode "r+", subsequent attempts to write to
> 'f' (e.g. with fprintf) will fail on MinGW when the gnulib fseek module
> is in use. The fseek module uses the fseeko module, which in turn uses
> the lseek module.
>
> Disabling these modules (using --avoid) fixed the problem for the
> reporter. I currently do not have access to a Windows system to
> investigate this further myself.
We would need a test case. And, moreover, one that does not involve fflush(),
ftell(), ftello(), fgetpos(), since these functions are known to not work
correctly on text-mode streams on mingw [1].
Bruno
[1] http://www.gnu.org/software/gnulib/manual/html_node/ftell.html