GNOME Bugzilla – Bug 690588
Wacom plugin uses 'int' instead of 'long' for 32-bit Xlib parameter
Last modified: 2013-01-02 16:09:04 UTC
Xlib expects 32-bit properties to be stored in longs, not ints. On 64-bit systems (where sizeof(int) < sizeof(long)), confusing the two can lead to garbage data at best, or a segfault at worst. The reset_touch_buttons function of gsd-wacom-manager.c suffers from this bug, using 'int action[2]' instead of 'long action[2]'. This leads to xf86-input-wacom receiving garbage instead of the intended second action, and is (partially) responsible for the touchring-triggers-modeswitch bug in recent versions of the driver.
Created attachment 232039 [details] [review] Proposed patch
Review of attachment 232039 [details] [review]: Commit after fixing that. Don't forget gnome-3-6! ::: plugins/wacom/gsd-wacom-manager.c @@ +630,3 @@ { char *propname; + unsigned long action[2]; /* press + release */ glong, not unsigned long.
Pushed to gnome-3-6 and master with the fix mentioned in the review.