|
From: | Gary V. Vaughan |
Subject: | Re: seekable stdin test failure on OS X |
Date: | Tue, 3 Apr 2007 10:51:19 +0100 |
Hi Eric, On 2 Apr 2007, at 18:15, Eric Blake-1 wrote:
Even on Linux, the fflush man page doesn't mention input streams: http://www.die.net/doc/linux/man/man3/fflush.3.html So it seems that using fflush(stdin) is probably the wrong thing to do altogether for a portable application.On the contrary, it makes it sound like we write a gnulib module that implements POSIX semantics of fflush, which creates a function rpl_fflush that calls fpurge or __fpurge under the hood when the regular fflush is broken on input streams; then portable applications can assume POSIX semantics for fflush.
Agreed, that is certainly the nicest way to work around it. Cheers, Gary -- ())_. Email me: address@hidden ( '/ Read my blog: http://blog.azazil.net / )= ...and my book: http://sources.redhat.com/autobook `(_~)_ Join my AGLOCO Network: http://www.agloco.com/r/BBBS7912
PGP.sig
Description: This is a digitally signed message part
[Prev in Thread] | Current Thread | [Next in Thread] |