summaryrefslogtreecommitdiff
path: root/xcb.c
diff options
context:
space:
mode:
authorMichael Stapelberg <michael@stapelberg.de>2010-07-20 20:52:58 +0200
committerMichael Stapelberg <michael@stapelberg.de>2010-07-20 20:52:58 +0200
commitc24922f0f2046b12a96f5cf9adc6f55f670ed990 (patch)
treee3f364a4618da6d0c5ff7b5aa90b43b19a1b121d /xcb.c
parent4e5c203cd937348f45dffe901deb11bb939a794b (diff)
Bugfix: Correctly error out when unable to grab pointer/keyboard
Diffstat (limited to 'xcb.c')
-rw-r--r--xcb.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/xcb.c b/xcb.c
index 032b523..f19d5c2 100644
--- a/xcb.c
+++ b/xcb.c
@@ -177,6 +177,6 @@ void grab_pointer_and_keyboard(xcb_connection_t *conn, xcb_screen_t *screen) {
}
}
- if (tries == 0)
+ if (tries <= 0)
errx(EXIT_FAILURE, "Cannot grab pointer/keyboard");
}