mirror of
https://git.tartarus.org/simon/putty.git
synced 2025-07-15 01:57:40 -05:00
Add some missing checks for EINTR after select(2).
I noticed today that Unix Plink responds to SIGWINCH by accidentally dying of EINTR having interrupted its main select loop, and when I checked, there turn out to be a couple of other select loops with the same bug.
This commit is contained in:
@ -531,7 +531,9 @@ static int ssh_sftp_do_select(int include_stdin, int no_fds_ok)
|
||||
now = GETTICKCOUNT();
|
||||
} while (ret < 0 && errno == EINTR);
|
||||
} else {
|
||||
ret = select(maxfd, &rset, &wset, &xset, NULL);
|
||||
do {
|
||||
ret = select(maxfd, &rset, &wset, &xset, NULL);
|
||||
} while (ret < 0 && errno == EINTR);
|
||||
}
|
||||
} while (ret == 0);
|
||||
|
||||
|
Reference in New Issue
Block a user