diff options
-rw-r--r-- | dix/getevents.c | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/dix/getevents.c b/dix/getevents.c index 279f49e54..9747b35a6 100644 --- a/dix/getevents.c +++ b/dix/getevents.c @@ -820,11 +820,15 @@ GetKeyboardValuatorEvents(EventList *events, DeviceIntPtr pDev, int type, if (noXkbExtension) #endif { - numEvents += GetKeyboardValuatorEvents(events, pDev, - KeyRelease, key_code, - first_valuator, num_valuators, - valuators); - events += numEvents; + int numReleaseEvents; + + numReleaseEvents = GetKeyboardValuatorEvents(events, pDev, + KeyRelease, key_code, + first_valuator, + num_valuators, + valuators); + numEvents += numReleaseEvents; + events += numReleaseEvents; } } |