poll.h vs sys/poll.h on QNX Neutrino

David Bacon bacon at cs.nyu.edu
Wed Sep 19 09:52:45 EST 2007


 From the ChangeLog:

    - dtucker at cvs.openbsd.org 2007/06/25 12:02:27
      [atomicio.c]
      Include <poll.h> like the man page says rather than <sys/poll.h>. 
  ok djm@

This was probably ill-advised given the
history of this header file.  Some older
systems, and some not-quite-XSI-compliant
systems such as QNX Neutrino, still have
<sys/poll.h> but not <poll.h>.

I suggest having configure.ac look for
both, and put the check for <poll.h> first
in atomicio.c, as in:

#ifdef HAVE_POLL_H
#include <poll.h>
#else
#ifdef HAVE_SYS_POLL_H
#include <sys/poll.h>
#endif
#endif

         dB


More information about the openssh-unix-dev mailing list