From 868ea76acfddfdc3c9553234f099eea2b58db066 Mon Sep 17 00:00:00 2001 From: Elias Naur Date: Fri, 24 Sep 2021 12:48:10 +0200 Subject: [PATCH] app: [X11] avoid deadlock when sending initial ConfigEvent Signed-off-by: Elias Naur --- app/os_x11.go | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/app/os_x11.go b/app/os_x11.go index b432fc9f..1a9115ca 100644 --- a/app/os_x11.go +++ b/app/os_x11.go @@ -733,12 +733,12 @@ func newX11Window(gioWin *callbacks, options []Option) error { // extensions C.XSetWMProtocols(dpy, win, &w.atoms.evDelWindow, 1) - w.Configure(options) - - // make the window visible on the screen - C.XMapWindow(dpy, win) - go func() { + w.Configure(options) + + // make the window visible on the screen + C.XMapWindow(dpy, win) + w.w.SetDriver(w) w.w.Event(ViewEvent{Display: unsafe.Pointer(dpy), Window: uintptr(win)}) w.setStage(system.StageRunning)