From a1a671eb952ccedb8588c1e39fcdce85c176d887 Mon Sep 17 00:00:00 2001 From: Ulf Hermann Date: Tue, 22 Feb 2022 12:31:08 +0100 Subject: [PATCH] Reduce memory leakage We need to clean up the event queue when we're done. Change-Id: I13a9eb77e978f4eab227a3a28dab8ebc8de94405 Reviewed-by: David Edmundson --- src/plugins/platforms/wayland/qwaylanddisplay.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/plugins/platforms/wayland/qwaylanddisplay.cpp b/src/plugins/platforms/wayland/qwaylanddisplay.cpp index 489a834d7c4..f8cb75e953b 100644 --- a/src/plugins/platforms/wayland/qwaylanddisplay.cpp +++ b/src/plugins/platforms/wayland/qwaylanddisplay.cpp @@ -393,6 +393,9 @@ QWaylandDisplay::~QWaylandDisplay(void) #endif if (mDisplay) wl_display_disconnect(mDisplay); + + if (m_frameEventQueue) + wl_event_queue_destroy(m_frameEventQueue); } // Steps which is called just after constructor. This separates registry_global() out of the constructor