diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2014-09-01 07:19:09 +0100 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2014-09-01 07:20:00 +0100 |
commit | 21cc987ca8a531e399350564a5af7f551406b8d6 (patch) | |
tree | 645b91717baa7a107aef9bfd07aa29bcc579758b | |
parent | 2c564c04bcde88d730ca111acfb6798bdf0d66da (diff) |
sna: Only decouple the event once
If the client and drawable destroys are racing, we may trigger the event
removal twice.
References: https://bugs.freedesktop.org/show_bug.cgi?id=83183
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
-rw-r--r-- | src/sna/sna_dri2.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/sna/sna_dri2.c b/src/sna/sna_dri2.c index 94bfcdab..61917cfa 100644 --- a/src/sna/sna_dri2.c +++ b/src/sna/sna_dri2.c @@ -1392,7 +1392,9 @@ sna_dri2_client_gone(CallbackListPtr *list, void *closure, void *data) assert(event->client == client); if (event->queued) { - sna_dri2_remove_event((WindowPtr)event->draw, event); + if (event->draw) + sna_dri2_remove_event((WindowPtr)event->draw, + event); event->client = NULL; event->draw = NULL; list_del(&event->link); |