mirror of
https://gitlab.freedesktop.org/xorg/xserver.git
synced 2026-01-03 17:30:13 +01:00
Xi: fix length field in XIQueryPointer.
Buttons append 4-byte units to the end of the reply, they need to be included too. Reported-by: Mark Dokter Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
This commit is contained in:
parent
33fcaaaea5
commit
b89dcfbfbd
1 changed files with 1 additions and 0 deletions
|
|
@ -127,6 +127,7 @@ ProcXIQueryPointer(ClientPtr client)
|
|||
{
|
||||
int i, down;
|
||||
rep.buttons_len = ((pDev->button->numButtons/8) + 3)/4;
|
||||
rep.length += rep.buttons_len;
|
||||
buttons = xcalloc(rep.buttons_len, 4);
|
||||
if (!buttons)
|
||||
return BadAlloc;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue