Re: PROBLEM: struct siginfo member si_fd not properly filled in handler after SIGIO (2.4.x) - offending POSIX specs?

Jamie Lokier (jamie@shareable.org)
Sat, 12 Jul 2003 21:23:17 +0100


Peter, in addition to:

if (fcntl(fd,F_SETOWN,getpid()) == -1) {perror("fault");}

you need to write:

if (fcntl(fd,F_SETSIG,SIGIO) == -1) {perror("fault");}

The fcntl() man page describes F_SETSIG. You'll also need to #define
_GNU_SOURCE as F_SETSIG isn't defined otherwise.

Enjoy,
-- Jamie
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/