Re: [PATCH] Call clearerr() on stdout before close_stream() is called.

2016-02-05 Thread David Cantrell
On Thu, Feb 04, 2016 at 08:16:30AM -0700, Eric Blake wrote: > On 02/04/2016 03:46 AM, David Cantrell wrote: > > This is seen in bison and possibly other programs. Bison will > > incorrectly receive SIGPIPE and terminate because close_stream() is > > picking up a rogue EP

[PATCH] Call clearerr() on stdout before close_stream() is called.

2016-02-04 Thread David Cantrell
This is seen in bison and possibly other programs. Bison will incorrectly receive SIGPIPE and terminate because close_stream() is picking up a rogue EPIPE in errno. Before fclose(), clearerr(stdout) needs to be called so that the errors it will check for are for the immediate call of close_stream