diff options
author | Sven Gothel <[email protected]> | 2019-12-06 08:43:05 +0100 |
---|---|---|
committer | Sven Gothel <[email protected]> | 2019-12-06 08:43:05 +0100 |
commit | 578edfc20915e2e2aa18aa06e49f7341f86990c4 (patch) | |
tree | 84925ab08c9745b42db1d59bc3a26b0776be4858 /src/newt/native/X11Display.c | |
parent | ddc29141207d9c69f8558265a464cdc4bc014d65 (diff) |
Bug 1413 - NEWT X11Window: NewtWindows_getFrameExtends(..) may hang on XPeekEvent(..)
The wait loop uses XPeekEvent(dpy, &e),
which can block indefinite if queue is empty.
Replace with timeout only _and_ only wait on CreateWindow0(..)
not when queried via X11Display dispatch loop on events
when it is assumed the information has been propagated already.
Diffstat (limited to 'src/newt/native/X11Display.c')
-rw-r--r-- | src/newt/native/X11Display.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/newt/native/X11Display.c b/src/newt/native/X11Display.c index abaabbb70..f3359b49e 100644 --- a/src/newt/native/X11Display.c +++ b/src/newt/native/X11Display.c @@ -761,7 +761,7 @@ JNIEXPORT void JNICALL Java_jogamp_newt_driver_x11_DisplayDriver_DispatchMessage int left=-1, right=-1, top=-1, bottom=-1; uint32_t netWMState = NewtWindows_getNET_WM_STATE(dpy, jw); int visibleChange = NewtWindows_updateVisibility(env, dpy, jw, netWMState, "ConfigureNotify"); - NewtWindows_updateInsets(dpy, jw, &left, &right, &top, &bottom); + NewtWindows_updateInsets(dpy, jw, False /* wait */, &left, &right, &top, &bottom); Bool maxChanged = NewtWindows_updateMaximized(dpy, jw, netWMState); (*env)->CallVoidMethod(env, jw->jwindow, sizePosMaxInsetsVisibleChangedID, JNI_FALSE, (jint) evt.xconfigure.x, (jint) evt.xconfigure.y, |