Displaying 2 results from an estimated 2 matches for "prev_fail".
2019 Sep 16
2
ssh client is setting O_NONBLOCK on a pipe shared with other processes
...to handle
EAGAIN or short counts. They *may* need to deal with EINTR but signals
don't come out of nowhere either and many programs run in an environment
where EINTR is also unexpected.
We are using GNU make 3.81 but newer versions of gmake do the same thing:
void
close_stdout (void)
{
int prev_fail = ferror (stdout);
int fclose_fail = fclose (stdout);
if (prev_fail || fclose_fail)
{
if (fclose_fail)
error (NILF, _("write error: %s"), strerror (errno));
else
error (NILF, _("write error"));
exit (EXIT_FAILURE);
}
}
On Sun, Sep...
2019 Sep 15
4
ssh client is setting O_NONBLOCK on a pipe shared with other processes
The quick summary is that we invoke git from a parallel invocation of
"make". Git invokes ssh to pull stuff from a remote repo. Ssh sets
O_NONBLOCK on stdout and stderr if they do not refer to a tty. During
our build, stderr refers to a pipe that other jobs run by make (and
make itself) may also write to, and since this is a parallel build,
they may write to that pipe while ssh has it