x11: Prevent handling some override-redirect window properties
It appears PyCharm can change WM_HINTS propery of override-redirect windows when they are closed, which triggers a crash in kwin. This change adds the corresponding guard. In addition to the icons, it adds a few more guards to prevent kwin crashing when a rogue client sets wrong properties on an override redirect window. BUG: 470874
This commit is contained in:
parent
73fac19d2a
commit
984af8f4f2
1 changed files with 9 additions and 0 deletions
|
@ -2414,6 +2414,9 @@ void X11Window::getMotifHints()
|
|||
|
||||
void X11Window::getIcons()
|
||||
{
|
||||
if (isUnmanaged()) {
|
||||
return;
|
||||
}
|
||||
// First read icons from the window itself
|
||||
const QString themedIconName = iconFromDesktopFile();
|
||||
if (!themedIconName.isEmpty()) {
|
||||
|
@ -3791,6 +3794,9 @@ void X11Window::getResourceClass()
|
|||
*/
|
||||
void X11Window::getWmNormalHints()
|
||||
{
|
||||
if (isUnmanaged()) {
|
||||
return;
|
||||
}
|
||||
const bool hadFixedAspect = m_geometryHints.hasAspect();
|
||||
// roundtrip to X server
|
||||
m_geometryHints.fetch();
|
||||
|
@ -5073,6 +5079,9 @@ void X11Window::readWmClientLeader(Xcb::Property &prop)
|
|||
|
||||
void X11Window::getWmClientLeader()
|
||||
{
|
||||
if (isUnmanaged()) {
|
||||
return;
|
||||
}
|
||||
auto prop = fetchWmClientLeader();
|
||||
readWmClientLeader(prop);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue