dix: set the correct length in CreateClassesChangedEvent.
Fallout from aeff14d5f2
. Yes, we don't malloc
anymore because we are inside a SIGIO and the memory is already there anyway.
But we still need to set the event length correctly, otherwise
mieqEnqueue/mieqProcessInputEvent don't know how much memory to copy.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
This commit is contained in:
parent
1001403301
commit
689be0cb4b
|
@ -119,6 +119,7 @@ CreateClassesChangedEvent(EventList* event,
|
|||
deviceClassesChangedEvent *dcce;
|
||||
int len = sizeof(xEvent);
|
||||
CARD32 ms = GetTimeInMillis();
|
||||
int namelen = 0; /* dummy */
|
||||
|
||||
dcce = (deviceClassesChangedEvent*)event->event;
|
||||
dcce->type = GenericEvent;
|
||||
|
@ -126,6 +127,7 @@ CreateClassesChangedEvent(EventList* event,
|
|||
dcce->evtype = XI_DeviceClassesChangedNotify;
|
||||
dcce->time = ms;
|
||||
dcce->new_slave = slave->id;
|
||||
SizeDeviceInfo(slave, &namelen, &len);
|
||||
dcce->length = (len - sizeof(xEvent))/4;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user