blob: 68670321ced1e3f6f6fd15197336f64932822e2d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
diff -Nur xf86-input-mouse-1.8.1.orig/src/bsd_mouse.c xf86-input-mouse-1.8.1/src/bsd_mouse.c
--- xf86-input-mouse-1.8.1.orig/src/bsd_mouse.c 2012-05-28 09:01:45.000000000 +0900
+++ xf86-input-mouse-1.8.1/src/bsd_mouse.c 2012-09-20 22:27:36.167583000 +0900
@@ -139,10 +139,10 @@
{
int i;
- for (i = 0; internalNames[i]; i++)
+ for (i = 0; i < (sizeof(internalNames) / sizeof(internalNames[0])) - 1; i++)
if (xf86NameCmp(protocol, internalNames[i]) == 0)
return TRUE;
- for (i = 0; miscNames[i]; i++)
+ for (i = 0; i < (sizeof(miscNames) / sizeof (miscNames[0])) - 1; i++)
if (xf86NameCmp(protocol, miscNames[i]) == 0)
return TRUE;
return FALSE;
|