Signed-off-by: Tiago Vignatti <[email protected]>
---
 hw/xfree86/xwayland/xwayland-window.c |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)

diff --git a/hw/xfree86/xwayland/xwayland-window.c 
b/hw/xfree86/xwayland/xwayland-window.c
index 101ef01..019f452 100644
--- a/hw/xfree86/xwayland/xwayland-window.c
+++ b/hw/xfree86/xwayland/xwayland-window.c
@@ -190,6 +190,11 @@ xwl_realize_window(WindowPtr window)
        xserver_set_window_id(xwl_screen->xorg_server,
                              xwl_window->surface, window->drawable.id);
 
+    /* we need to wait in order to avoid a race with Weston WM, when it would
+     * try to anticipate XCB_MAP_NOTIFY, requiring create_surface completed
+     * (for shell_surface_set_toplevel) */
+    wl_display_roundtrip(xwl_screen->display);
+
     wl_surface_set_user_data(xwl_window->surface, xwl_window);
     xwl_window_attach(xwl_window, (*screen->GetWindowPixmap)(window));
 
-- 
1.7.5.4

_______________________________________________
wayland-devel mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/wayland-devel

Reply via email to