diff options
author | Keith Packard <keithp@keithp.com> | 2010-12-06 20:38:14 -0800 |
---|---|---|
committer | Keith Packard <keithp@keithp.com> | 2010-12-06 20:38:14 -0800 |
commit | 435361bd73b9fc733f093d81af6b839953e35176 (patch) | |
tree | 980eb5f789361774d6e7de791dd0bfce1b733e1a /Xext | |
parent | 0d01b66df9081ef48843b3bad81c56bb2cd1ae69 (diff) |
sync: syncObject may be None in SyncInitTrigger
And often is, especially when called from ProcSyncCreateAlarm.
Crashing in this case seems unwise.
Signed-off-by: Keith Packard <keithp@keithp.com>
Diffstat (limited to 'Xext')
-rw-r--r-- | Xext/sync.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Xext/sync.c b/Xext/sync.c index ce00755b4..ab8f20d5c 100644 --- a/Xext/sync.c +++ b/Xext/sync.c @@ -296,7 +296,7 @@ SyncInitTrigger(ClientPtr client, SyncTrigger *pTrigger, XID syncObject, /* if system counter, ask it what the current value is */ - if (SYNC_COUNTER == pSync->type) + if (pSync && SYNC_COUNTER == pSync->type) { pCounter = (SyncCounter *)pSync; @@ -320,7 +320,7 @@ SyncInitTrigger(ClientPtr client, SyncTrigger *pTrigger, XID syncObject, if (changes & XSyncCATestType) { - if (SYNC_FENCE == pSync->type) + if (pSync && SYNC_FENCE == pSync->type) { pTrigger->CheckTrigger = SyncCheckTriggerFence; } |