Linux poll issue

[I originally send this and it didn't complain.  hmm...]

Linux 2.2.14 and earlier versions doesn't like it when you poll more file
descriptors than you have [1].  Unfortunately, glib does this, if the
programmer calls add_watch multiple times for the same channel (ie, file
descriptor).  (I'm not sure if glib does it internally too.)


- Fix Linux.  This may have been fixed in Janauary.  I can't tell from
   mailing list.
- Patch g_main_poll to create only one GPollFD per FD.  This may require
   extra bookkeeping and/or loops.
- Detect in glib's configure and undefine HAVE_POLL to use g_poll.


- Detect in your programs configure and define poll, which will override
   glibc's poll.  This is hacky, but probably what I'll end up doing.
- Call add_watch only once for each iochannel.  I think I can do this, but
   I'd rather not.



      __          _    __ 
  ___/ /__ __  __(_)__/ /  David Helder - University of Michigan
 / _  / _ `/ |/ / / _  /

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]