Fix unlikely race (or crawl?) condition in case going from alarm to ioctl takes more than 1 second
This commit is contained in:
parent
90285c46a2
commit
330374be9e
1 changed files with 1 additions and 0 deletions
|
@ -96,6 +96,7 @@ void closefd(fd_t *fdp)
|
|||
static void timeout(int signum)
|
||||
{
|
||||
/* nothing to do, ioctl will be aborted automatically */
|
||||
if (alarm(1) < 0) fatal("alarm(1)");
|
||||
}
|
||||
|
||||
int opendev(network_t *np, fdtype_t fdtype, int compete)
|
||||
|
|
Loading…
Reference in a new issue