mirror of
https://gitlab.freedesktop.org/xorg/xserver.git
synced 2026-06-13 10:38:43 +02:00
Xi/exevents: fix off-by-one in UpdateDeviceState valuator bounds check
There is no OOB write, the loop a few lines below has the correct i < numAxes check. But this does set last_valuator to an invalid value which may have flow-on effects elsewhere later. Assisted-by: Claude:claude-claude-opus-4-6 Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2200>
This commit is contained in:
parent
0669520727
commit
1f123a264b
1 changed files with 1 additions and 1 deletions
|
|
@ -904,7 +904,7 @@ UpdateDeviceState(DeviceIntPtr device, DeviceEvent *event)
|
|||
"Ignoring event.\n", device->name);
|
||||
return DONT_PROCESS;
|
||||
}
|
||||
else if (v->numAxes < i) {
|
||||
else if (v->numAxes <= i) {
|
||||
ErrorF("[Xi] Too many valuators reported for device '%s'. "
|
||||
"Ignoring event.\n", device->name);
|
||||
return DONT_PROCESS;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue