summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorDavid Edmundson <davidedmundson@kde.org>2023-12-15 08:57:47 +0000
committerQt Cherry-pick Bot <cherrypick_bot@qt-project.org>2023-12-21 19:36:57 +0000
commit3cecce166ebe24373d08c4c73387fc92c257d63a (patch)
treeecfd16bb33c6fd80f605315faaa2a1aaf8da751f /src
parent32ad01026f74e92374b32e94d4b99904eaf5d22f (diff)
client: Clean up text input proxy object in textinputv2
This not only cleans up a tiny amount of memory, but also fixes a potential crash if a wayland event were to arrive on the object after the Qt level wrapper is destroyed. Pick-to: 6.5 Change-Id: I6fafdd848d61da893304c4467a57b52d3771c508 Reviewed-by: Liang Qi <liang.qi@qt.io> (cherry picked from commit 18166784fda5b3afce55bf00227f77e08ff08ac2) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org> (cherry picked from commit f5bcf869810fee9882cbd1d7208e625862724259)
Diffstat (limited to 'src')
-rw-r--r--src/client/qwaylandtextinputv2.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/client/qwaylandtextinputv2.cpp b/src/client/qwaylandtextinputv2.cpp
index a799793e5..89a8a6d77 100644
--- a/src/client/qwaylandtextinputv2.cpp
+++ b/src/client/qwaylandtextinputv2.cpp
@@ -46,6 +46,7 @@ QWaylandTextInputv2::~QWaylandTextInputv2()
{
if (m_resetCallback)
wl_callback_destroy(m_resetCallback);
+ destroy();
}
void QWaylandTextInputv2::reset()