On Sun, 27 Dec 1998, compiler wrote:

> Will someone please explain to me why this call to select won't return?
> 
> #include <stdio.h>
> #include <unistd.h>
> #include <sys/types.h>

/* missing <sys/time.h> */
 
>         n = select(1,&mainset,NULL,NULL,NULL);

I only eyeballed this so I may have missed something,
but this stands out. The first argument to select is 
the highest descriptor to monitor _plus one_. Change it to 

select(localpipes[0]+1,&mainset,NULL,NULL,NULL);
 
and it should work. 



Reply via email to