Summary: | Kwin crash to do with hidden, empty or otherwise odd window titles | ||
---|---|---|---|
Product: | [Plasma] kwin | Reporter: | Nick Leverton <nick> |
Component: | tabbox | Assignee: | Martin Flöser <mgraesslin> |
Status: | RESOLVED FIXED | ||
Severity: | crash | CC: | kwin-bugs-null |
Priority: | NOR | Flags: | mgraesslin:
ReviewRequest+
|
Version: | unspecified | ||
Target Milestone: | 4.9.0 | ||
Platform: | Ubuntu | ||
OS: | Linux | ||
URL: | https://git.reviewboard.kde.org/r/105645/ | ||
Latest Commit: | http://commits.kde.org/kde-workspace/ff0f879b66e275030570d9d36909e7fecd01b3ec | Version Fixed In: | 4.9.0 |
Sentry Crash Report: | |||
Attachments: | Most likely fix |
Description
Nick Leverton
2012-07-20 10:23:02 UTC
Created attachment 72645 [details]
Most likely fix
would you have a chance to reproduce the situation and test this patch? Pretty sure it will fix the crash but would be nice nevertheless :-)
Added a review request with a unit test to simulate the crash: https://git.reviewboard.kde.org/r/105645/ Git commit ff0f879b66e275030570d9d36909e7fecd01b3ec by Martin Gräßlin. Committed on 21/07/2012 at 11:25. Pushed by graesslin into branch 'KDE/4.9'. Verify pointer is valid when calculating the longest caption The method was missing a check whether the weak pointers in the internal list got deleted. This could in very unlikely cases lead to a crash. In order to verify that adding the null pointer check fixes the crash a unit test is added to simulate the situation of a pointer being deleted. This required to add a mock a few classes of TabBox. A MockTabBoxHandler and MockTabBoxClient are added implementing the specific interfaces. The DeclarativeView is completely mocked to make the linker happy. Including the actual implementation is not possible as it pulls in half of KWin core. FIXED-IN: 4.9.0 REVIEW: 105645 M +1 -0 kwin/tabbox/CMakeLists.txt M +3 -0 kwin/tabbox/clientmodel.cpp A +17 -0 kwin/tabbox/tests/CMakeLists.txt A +94 -0 kwin/tabbox/tests/mock_declarative.cpp [License: GPL (v2)] A +38 -0 kwin/tabbox/tests/mock_tabboxclient.cpp [License: GPL (v2)] A +67 -0 kwin/tabbox/tests/mock_tabboxclient.h [License: GPL (v2)] A +99 -0 kwin/tabbox/tests/mock_tabboxhandler.cpp [License: GPL (v2)] A +93 -0 kwin/tabbox/tests/mock_tabboxhandler.h [License: GPL (v2)] A +47 -0 kwin/tabbox/tests/test_tabbox_clientmodel.cpp [License: GPL (v2)] A +38 -0 kwin/tabbox/tests/test_tabbox_clientmodel.h [License: GPL (v2)] http://commits.kde.org/kde-workspace/ff0f879b66e275030570d9d36909e7fecd01b3ec |