summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Hutterer <peter.hutterer@who-t.net>2011-10-19 12:28:37 +1000
committerPeter Hutterer <peter.hutterer@who-t.net>2011-10-25 14:06:41 +1000
commit1f4af6c12fb5d4c19f4eac3df768517c9132cc88 (patch)
treedaa8d03e5940d152487541202b3595a3f79a43c6
parentd77dec6971e4a0b306c8dbd5adf627908d7972cb (diff)
dix: accept a NULL master for CreateClassesChangedEvent
If a floating device changes, the master is NULL but we must still create a DCE for it. Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net> Reviewed-by: Daniel Stone <daniel@fooishbar.org>
-rw-r--r--dix/getevents.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/dix/getevents.c b/dix/getevents.c
index 8057e6296..4845a106c 100644
--- a/dix/getevents.c
+++ b/dix/getevents.c
@@ -218,7 +218,7 @@ CreateClassesChangedEvent(InternalEvent* event,
dce = &event->changed_event;
memset(dce, 0, sizeof(DeviceChangedEvent));
dce->deviceid = slave->id;
- dce->masterid = master->id;
+ dce->masterid = master ? master->id : 0;
dce->header = ET_Internal;
dce->length = sizeof(DeviceChangedEvent);
dce->type = ET_DeviceChanged;