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

From: Jamie Lokier (jamie@shareable.org)
Date: Sat Jul 12 2003 - 15:23:17 EST


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/



This archive was generated by hypermail 2b29 : Tue Jul 15 2003 - 22:00:45 EST