summaryrefslogtreecommitdiffstats
path: root/x11vnc/uinput.c
diff options
context:
space:
mode:
authorrunge <runge>2006-12-28 17:57:10 +0000
committerrunge <runge>2006-12-28 17:57:10 +0000
commitf9baaf1ee49e7889808b1f058a5f348a9cd5f027 (patch)
tree67b130f468967c942662f620950e188672d84e60 /x11vnc/uinput.c
parent99a557d673ac4444532ac7025cb479a229ea7fb3 (diff)
downloadlibtdevnc-f9baaf1ee49e7889808b1f058a5f348a9cd5f027.tar.gz
libtdevnc-f9baaf1ee49e7889808b1f058a5f348a9cd5f027.zip
more compiler warnings cleanup.
Diffstat (limited to 'x11vnc/uinput.c')
-rw-r--r--x11vnc/uinput.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/x11vnc/uinput.c b/x11vnc/uinput.c
index c25f212..680c09d 100644
--- a/x11vnc/uinput.c
+++ b/x11vnc/uinput.c
@@ -82,10 +82,10 @@ static char *devs[] = {
*/
int check_uinput(void) {
- int i;
#ifndef UINPUT_OK
return 0;
#else
+ int i;
if (UT.release) {
int maj, min;
/* guard against linux 2.4 */
@@ -455,6 +455,8 @@ static void ptr_move(int dx, int dy) {
ev.code = SYN_REPORT;
ev.value = 0;
write(fd, &ev, sizeof(ev));
+#else
+ if (!dx || !dy) {}
#endif
}
@@ -485,6 +487,8 @@ static void ptr_abs(int x, int y) {
ev.code = SYN_REPORT;
ev.value = 0;
write(fd, &ev, sizeof(ev));
+#else
+ if (!x || !y) {}
#endif
}
@@ -668,7 +672,8 @@ static void button_click(int down, int btn) {
write(fd, &ev, sizeof(ev));
last_button_click = dnow();
-
+#else
+ if (!down || !btn) {}
#endif
}
@@ -910,6 +915,8 @@ void uinput_key_command(int down, int keysym, rfbClientPtr client) {
if (0 <= scancode && scancode < 256) {
key_pressed[scancode] = down ? 1 : 0;
}
+#else
+ if (!down || !keysym || !client) {}
#endif
}