Thread (75 messages) 75 messages, 5 authors, 2011-01-28

Re: 2.6.36/2.6.37: broken compatibility with userspace input-utils ?

From: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Date: 2011-01-26 16:51:45
Also in: linux-input, lkml

On Wed, Jan 26, 2011 at 12:18:29PM -0200, Mauro Carvalho Chehab wrote:
quoted hunk ↗ jump to hunk
diff --git a/input.c b/input.c
index d57a31e..a9bd5e8 100644
--- a/input.c
+++ b/input.c
@@ -101,8 +101,8 @@ int device_open(int nr, int verbose)
 		close(fd);
 		return -1;
 	}
-	if (EV_VERSION != version) {
-		fprintf(stderr, "protocol version mismatch (expected %d, got %d)\n",
+	if (EV_VERSION > version) {
+		fprintf(stderr, "protocol version mismatch (expected >= %d, got %d)\n",
 			EV_VERSION, version);
Please do not do this. It causes check to "float" depending on the
version of kernel headers it was compiled against.

The check should be against concrete version (0x10000 in this case).

Thanks.

-- 
Dmitry
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help