mirror of
https://github.com/X11Libre/xf86-input-synaptics.git
synced 2026-04-14 11:54:16 +00:00
Fixed change b5ae101d5d so that the
autodetection works also when X>=10 in eventX. (Pointed out by Hartwig Felger.)
This commit is contained in:
@@ -245,7 +245,10 @@ SetDeviceAndProtocol(LocalDevicePtr local)
|
||||
event_device=NULL;
|
||||
s=strstr(line+sizeof(INP_DEV_H)-1, "event"); /* there might also be some other devices f.e. js0... */
|
||||
if(s != NULL) {
|
||||
s[sizeof("event")]='\0'; /* terminate the string after event2 */
|
||||
char *p = s + sizeof("event");
|
||||
while (*p && (*p >= '0') && (*p <= '9'))
|
||||
p++;
|
||||
*p = 0; /* terminate the string after event2 */
|
||||
event_device = malloc(strlen(s) + sizeof(DEV_INPUT_EVENT) + 1);
|
||||
}
|
||||
if(s == NULL || event_device == NULL) {
|
||||
|
||||
Reference in New Issue
Block a user