From: Drew Fisher Date: Mon, 14 Nov 2011 19:39:36 +0000 (-0800) Subject: touchmouse_process_events_timeout(): obey documentation's semantics X-Git-Url: http://git.zarvox.org/static/main.js?a=commitdiff_plain;h=1bf3ce0223124195cce49577a700239ab527d724;p=libtouchmouse.git touchmouse_process_events_timeout(): obey documentation's semantics Signed-off-by: Drew Fisher --- diff --git a/src/touchmouse.c b/src/touchmouse.c index bc7ad48..3cbd60d 100644 --- a/src/touchmouse.c +++ b/src/touchmouse.c @@ -337,7 +337,7 @@ int touchmouse_process_events_timeout(touchmouse_device *dev, int milliseconds) unsigned char data[256] = {}; int res; uint64_t deadline; - if(milliseconds == -1) { + if(milliseconds < 0) { deadline = (uint64_t)(-1); } else { deadline = mono_timer_nanos() + (milliseconds * 1000000);