Check for potential infinite select() loops when building

This commit is contained in:
Eelco Dolstra 2012-12-18 18:50:05 +01:00
parent a9045c727f
commit cc511fd65b

View file

@ -3141,6 +3141,8 @@ void Worker::waitForInput()
}
}
assert(fdMax != 0);
if (select(fdMax, &fds, 0, 0, useTimeout ? &timeout : 0) == -1) {
if (errno == EINTR) return;
throw SysError("waiting for input");