fdevent_solaris_port.c header missing on Solaris 10
Solaris/Sparc 10 1/13 , gcc 5.5.0
fdevent_solaris_port.c:21:49: error: 'POLLIN' undeclared here (not in a function)
static const int SOLARIS_PORT_POLL_READ = POLLIN;
According to Oracle's man page (on the web), #include <port.h> is what is needed. See the example near the bottom of the page.
Maybe we need an additional feature #define to get POLLIN? You'll have to look in the system headers. Sorry, I do not have access to a Solaris 10 system.
Now then, I can add an additional include, but inet/ip.h does not seem to be the minimal required. Perhaps sys/ioctl.h or sys/filio.h? Event ports work on more than just IP sockets, so the include for this define should be something more general.
Please take another look. Thanks.
--- a/src/fdevent_solaris_port.c +++ b/src/fdevent_solaris_port.c @@ -15,6 +15,7 @@ #ifdef FDEVENT_USE_SOLARIS_PORT +#include <sys/poll.h> static const int SOLARIS_PORT_POLL_READ = POLLIN; static const int SOLARIS_PORT_POLL_WRITE = POLLOUT; static const int SOLARIS_PORT_POLL_READ_WRITE = POLLIN & POLLOUT;
Also available in: Atom