Add a comment to the waitattach code.
This commit is contained in:
parent
5f6d552d2c
commit
e06f8dfcdf
13
master.c
13
master.c
|
|
@ -444,9 +444,16 @@ master_process(int s, char **argv, int waitattach)
|
||||||
FD_SET(s, &readfds);
|
FD_SET(s, &readfds);
|
||||||
highest_fd = s;
|
highest_fd = s;
|
||||||
|
|
||||||
if (clients && clients->attached)
|
/*
|
||||||
waitattach = 0;
|
** When waitattach is set, wait until the client attaches
|
||||||
if (!waitattach)
|
** before trying to read from the pty.
|
||||||
|
*/
|
||||||
|
if (waitattach)
|
||||||
|
{
|
||||||
|
if (clients && clients->attached)
|
||||||
|
waitattach = 0;
|
||||||
|
}
|
||||||
|
else
|
||||||
{
|
{
|
||||||
FD_SET(the_pty.fd, &readfds);
|
FD_SET(the_pty.fd, &readfds);
|
||||||
if (the_pty.fd > highest_fd)
|
if (the_pty.fd > highest_fd)
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue