Eric Blake wrote:
> But even if cygwin is improved to not trigger an internal fault, and/or
> libsigsegv changed to not interfere with cygwin's detection of internal 
> faults,
> it seems that the real root cause is that gnulib has caused the application to
> perform undefined behavior during the atexit() handler, and that we should fix
> this before it trips up other platforms.  What's the best way to do that?  
> Have
> close_stdout call freopen("/dev/null","w",stdout) prior to calling error()?
> Convince the glibc folks to change error() to not call fflush(stdout) if 
> fileno
> (stdout) is closed?  Rewrite close_stdout to open-code the error-printing
> actions instead of calling error()?  Something else?

How about fixing gnulib's lib/error.c to do the right thing?
Then if you teach m4/error.m4 to detect when glibc's error function
is defective (currently always) it can use the improved replacement.


Reply via email to