summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoel Bosveld <Joel.Bosveld@gmail.com>2009-04-24 10:12:26 -0700
committerAlan Coopersmith <alan.coopersmith@sun.com>2009-04-24 10:12:26 -0700
commita1c98f7fa9aa0cd5075ef2054c5d2be4d1e740f0 (patch)
tree360475fd64acde42bcdda1927a9444a6bbcd00c4
parent64b7f96dca23d2b33e0b8a8785d628d9a2f50e7b (diff)
Correct fcntl(F_SETOWN) error check in non-Solaris sigio code
commit 64b7f96dca accidentally inverted the comparison, could result in crashes on some systems later on. Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com>
-rw-r--r--hw/xfree86/os-support/shared/sigio.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/hw/xfree86/os-support/shared/sigio.c b/hw/xfree86/os-support/shared/sigio.c
index 256578289..5ba0b7e1c 100644
--- a/hw/xfree86/os-support/shared/sigio.c
+++ b/hw/xfree86/os-support/shared/sigio.c
@@ -157,7 +157,7 @@ xf86InstallSIGIOHandler(int fd, void (*f)(int, void *), void *closure)
xf86Msg(X_WARNING, "fcntl(%d, O_ASYNC): %s\n",
fd, strerror(errno));
} else {
- if (fcntl(fd, F_SETOWN, getpid()) != -1) {
+ if (fcntl(fd, F_SETOWN, getpid()) == -1) {
xf86Msg(X_WARNING, "fcntl(%d, F_SETOWN): %s\n",
fd, strerror(errno));
} else {