summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--xcb.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/xcb.c b/xcb.c
index f1a9a76..3e8cd07 100644
--- a/xcb.c
+++ b/xcb.c
@@ -10,6 +10,7 @@
#include <xcb/xcb.h>
#include <xcb/xcb_image.h>
#include <xcb/xcb_atom.h>
+#include <xcb/xcb_aux.h>
#include <stdio.h>
#include <stdlib.h>
#include <stdbool.h>
@@ -150,6 +151,9 @@ xcb_window_t open_fullscreen_window(xcb_connection_t *conn, xcb_screen_t *scr, c
values[0] = XCB_STACK_MODE_ABOVE;
xcb_configure_window(conn, win, XCB_CONFIG_WINDOW_STACK_MODE, values);
+ /* Ensure that the window is created and set up before returning */
+ xcb_aux_sync(conn);
+
return win;
}