bug-gnulib
[Top][All Lists]
Advanced

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

Re: 'fflush' test failure on Cygwin


From: Bruno Haible
Subject: Re: 'fflush' test failure on Cygwin
Date: Fri, 13 Apr 2007 16:40:11 +0200
User-agent: KMail/1.5.4

Eric Blake wrote:
> what I do is make rpl_fflush check if fp->_seek is __sseek, in
> which case I replace it with rpl_sseek.  rpl_sseek is written to call
> __sseek, and to restore __sseek to fp->_seek if whence is not SEEK_CUR.

Whee... You are aware that here you hook yourself into an API that is
completely undocumented? Where not only the functions can be renamed
without notice, but even where the arguments can be swapped, the meanings
of the arguments can be changed, without notice?

This level of hooks is probably the only one that you can use if you want
to implement fmemopen() and open_memstream().

But here, I would think a solution that hooks into the documented API (fseek)
will cause ten times less portability problems.

Bruno





reply via email to

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