From 34eb146db7753e59109022a2394bdb67bc9db0a7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Gr=C3=A4=C3=9Flin?= Date: Mon, 22 Aug 2016 15:57:25 +0200 Subject: [PATCH] [autotests] Try to make TestWindowManagement more robust The test started to segfault on build.kde.org. It looks like an event survives the destruction of the server. Thus this change tries to dispatchEvents once more before destroying everything. --- src/wayland/autotests/client/test_wayland_windowmanagement.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/wayland/autotests/client/test_wayland_windowmanagement.cpp b/src/wayland/autotests/client/test_wayland_windowmanagement.cpp index fbd92bd301..e0269e198b 100644 --- a/src/wayland/autotests/client/test_wayland_windowmanagement.cpp +++ b/src/wayland/autotests/client/test_wayland_windowmanagement.cpp @@ -226,6 +226,7 @@ void TestWindowManagement::cleanup() } if (m_thread) { if (m_connection) { + m_connection->flush(); m_connection->deleteLater(); } m_thread->quit(); @@ -235,6 +236,7 @@ void TestWindowManagement::cleanup() } m_connection = nullptr; + m_display->dispatchEvents(); delete m_windowManagementInterface; m_windowManagementInterface = nullptr;