| Summary: | Plasma crash after update | ||
|---|---|---|---|
| Product: | [Plasma] plasmashell | Reporter: | OliPro007 |
| Component: | general | Assignee: | David Edmundson <kde> |
| Status: | RESOLVED FIXED | ||
| Severity: | crash | CC: | bshah, notmart, plasma-bugs-null |
| Priority: | LO | Keywords: | drkonqi |
| Version First Reported In: | 5.8.3 | ||
| Target Milestone: | 1.0 | ||
| Platform: | Arch Linux | ||
| OS: | Linux | ||
| Latest Commit: | http://commits.kde.org/plasma-framework/760fb53e7dcc873f4ec90e726d16f766daabf99f | Version Fixed/Implemented In: | |
| Sentry Crash Report: | |||
|
Description
OliPro007
2016-11-19 02:24:53 UTC
That means we're hitting: KPLUGININFO_ISVALID_ASSERTION and we're using metadata object for an invalid metatadata. Grep shows the only direct calls to KPluginInfo::version are in ThemePrivate. We're not handling a theme being removed (even if temporarily) at runtime. It's a bug in our code, but it's pretty obscure. either settingsFileChanged() or useCache() more debug symbols could be useful to see which it is, bu we can try to guard those two.. probably is useCache() as is called in a timer trigger (so can happen the timer is started when the theme is still there and triggered when it's already gone (In reply to Marco Martin from comment #2) > probably is useCache() as is called in a timer trigger (so can happen the > timer is started when the theme is still there and triggered when it's > already gone hmm, actually not, in useCache we explicitly check the file exists just before. in settingsFileChanged it's using a cached themeMetadataPath that may have been deleted in the meantime can be something as easy as that, tough what would then happen is the theme being not really functional anymore (that's why didn't do a rr yet)
maybe, in the case pluginifo is not valid, useCache() can be called again, causing a reevaluation of themeMetadataPath
index 0f3662e..dc50852 100644
--- a/src/plasma/private/theme_p.cpp
+++ b/src/plasma/private/theme_p.cpp
@@ -582,7 +582,7 @@ void ThemePrivate::settingsFileChanged(const QString &file)
qCDebug(LOG_PLASMA) << "settingsFile: " << file;
if (file == themeMetadataPath) {
const KPluginInfo pluginInfo(themeMetadataPath);
- if (themeVersion != pluginInfo.version()) {
+ if (pluginInfo.isValid() && themeVersion != pluginInfo.version()) {
scheduleThemeChangeNotification(SvgElementsCache);
}
} else if (file.endsWith(QLatin1String(themeRcFile))) {
yeah, I reached the same conclusion earlier: https://git.reviewboard.kde.org/r/129436/ Git commit 760fb53e7dcc873f4ec90e726d16f766daabf99f by David Edmundson. Committed on 22/11/2016 at 10:44. Pushed by davidedmundson into branch 'master'. Check for metadata validty in settingsFileChanged settingsFileChanged is called if the plugin metadata file changes, and reloads the theme if the version changes. However, if the metadata file now doesn't exist we need to check before calling .version() otherwise it will assert. If it doesn't exist, we want to reload the theme so that it will load the correct thing. REVIEW: 129436 M +1 -1 src/plasma/private/theme_p.cpp http://commits.kde.org/plasma-framework/760fb53e7dcc873f4ec90e726d16f766daabf99f |