File: 0039-Reduce-memory-leakage.patch

package info (click to toggle)
qtwayland-opensource-src 5.15.17-1
  • links: PTS, VCS
  • area: main
  • in suites: experimental
  • size: 11,108 kB
  • sloc: cpp: 53,691; xml: 9,462; ansic: 187; makefile: 29; sh: 5
file content (26 lines) | stat: -rw-r--r-- 891 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
From 2197557879ae1e3459e715dbc20b21e8652cb972 Mon Sep 17 00:00:00 2001
From: Ulf Hermann <ulf.hermann@qt.io>
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 <davidedmundson@kde.org>
(cherry picked from commit 1264e5f565d8fb7ac200e4b00531ab876922458f)
---
 src/client/qwaylanddisplay.cpp | 3 +++
 1 file changed, 3 insertions(+)

--- a/src/client/qwaylanddisplay.cpp
+++ b/src/client/qwaylanddisplay.cpp
@@ -381,6 +381,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