Comment 6 for bug 180884

Revision history for this message
In , Peter Hutterer (peter-hutterer) wrote :

(In reply to comment #3)
> After a bit of wrestling, I got xorg to debug again. The device is "eraser".
> Naturally, eraser has no LEDs, as it's part of a passive pen device!
>

please try the simple patch below. i think the correct fix would be in the caller but i don't know enough about XKB for that.

diff --git a/xkb/xkbLEDs.c b/xkb/xkbLEDs.c
index 2877af0..55ce12a 100644
--- a/xkb/xkbLEDs.c
+++ b/xkb/xkbLEDs.c
@@ -63,6 +63,9 @@ XkbSrvLedInfoPtr sli;

     sli= XkbFindSrvLedInfo(dev,XkbDfltXIClass,XkbDfltXIId,0);

+ if (!sli)
+ return update;
+
     if (state_changes&(XkbModifierStateMask|XkbGroupStateMask))
  update|= sli->usesEffective;
     if (state_changes&(XkbModifierBaseMask|XkbGroupBaseMask))