(EmptyTerminal): check that fds are not too large to select on
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@9105 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
@@ -817,6 +817,9 @@ EmptyTerminal(void)
|
|||||||
|
|
||||||
FD_ZERO(&outs);
|
FD_ZERO(&outs);
|
||||||
|
|
||||||
|
if (tout >= FD_SETSIZE)
|
||||||
|
fatal (, "fd too large");
|
||||||
|
|
||||||
if (TTYBYTES() == 0) {
|
if (TTYBYTES() == 0) {
|
||||||
FD_SET(tout, &outs);
|
FD_SET(tout, &outs);
|
||||||
select(tout+1, 0, &outs, 0,
|
select(tout+1, 0, &outs, 0,
|
||||||
|
Reference in New Issue
Block a user