Commit 3092043b authored by David Edmundson's avatar David Edmundson

[platforms/x11] Fix valigrind warning copying window icon for windowed mode

windowIcon.pixmap().bits() creates and deletes the QPixmap object.

Which means data is dangling when we call m_winInfo->setIcon()

Surprisingly harmless in real life.

Test Plan: Reran kwin_wayland on X11 with valigrind

Reviewers: #kwin, apol

Reviewed By: apol

Subscribers: zzag, kwin

Tags: #kwin

Differential Revision:
parent bc199170
......@@ -104,7 +104,8 @@ void X11WindowedOutput::init(const QPoint &logicalPosition, const QSize &pixelSi
NETIcon icon; = windowIcon.pixmap(size).toImage().bits();
QImage windowImage = windowIcon.pixmap(size).toImage(); = windowImage.bits();
icon.size.width = size.width();
icon.size.height = size.height();
m_winInfo->setIcon(icon, false);
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment