mirror of
https://gitlab.freedesktop.org/xorg/lib/libx11.git
synced 2026-05-07 19:08:11 +02:00
If we have not actually put the buffer back, deferred invariants may not hold. This is OK.
This commit is contained in:
parent
434bf80b40
commit
67d06e0fe4
1 changed files with 10 additions and 4 deletions
|
|
@ -41,11 +41,17 @@ static void _XUnlockDisplay(Display *dpy)
|
|||
{
|
||||
--dpy->xcl->lock_count;
|
||||
_XPutXCBBufferIf(dpy, _XBufferUnlocked);
|
||||
assert(XCBGetRequestSent(XCBConnectionOfDisplay(dpy)) == dpy->request);
|
||||
|
||||
/* Traditional Xlib does this in _XSend; see the Xlib/XCB version
|
||||
* of that function for why we do it here instead. */
|
||||
_XSetSeqSyncFunction(dpy);
|
||||
/* If we're unlocking all the way, make sure that our deferred
|
||||
* invariants hold. */
|
||||
if(!dpy->xcl->lock_count)
|
||||
{
|
||||
assert(XCBGetRequestSent(XCBConnectionOfDisplay(dpy)) == dpy->request);
|
||||
|
||||
/* Traditional Xlib does this in _XSend; see the Xlib/XCB version
|
||||
* of that function for why we do it here instead. */
|
||||
_XSetSeqSyncFunction(dpy);
|
||||
}
|
||||
|
||||
pthread_mutex_unlock(XCBGetIOLock(XCBConnectionOfDisplay(dpy)));
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue