FD_SET clears some file descriptors from set?

FD_SET clears some file descriptors from set?

Post by Nancy A. Mill » Thu, 20 Apr 1995 04:00:00



I'm trying to use select() to implement a server that can handle
multiple open socket descriptors at a time.  Everything is ok
when I add the first two file descriptors to the "read set" (the
set of descriptors select() is supposed to check for read io).
But whenever I try to add a third descriptor, one of the other
two gets removed from the set!  I'm using this under Solaris
2.3... could that have something to do with it?  (I know select is
a BSD thing.)  Has anyone seen this before?  How can I fix it?

Thanks,
Nancy