Hidden KDED desktop file crashing systemsettings - where to fix?

Sebastian TrĂ¼g trueg at kde.org
Tue Nov 2 08:41:22 GMT 2010

On 11/02/2010 09:26 AM, Jonathan Marten wrote:
> Dear all,
> Since it got committed to trunk a few days ago, the new activity
> manager (kdebase/runtime/activitymanager) crashes the "kcmkded"
> systemsettings module:
> ASSERT: "file.desktopGroup().readEntry("X-KDE-ServiceTypes") == "KDEDModule""
> in file /ws/trunk/kdebase/runtime/kcontrol/kded/kcmkded.cpp, line 190
> This seems to be because it installs a desktop file
> (share/kde4/services/kded/activitymanager.desktop) which contains
> only:
> [Desktop Entry]
> Hidden=true
> KDEDConfig::load() simply lists all the desktop files in the "kded"
> subdirectory - it does not check whether the desktop file is hidden,
> therefore hitting the assert later.
> So my question: where is the best place to fix this?  Should it be:
> a) add the required (plus some dummy) entries to
> activitymanager.desktop, until its final version is in place.  Just
> adding X-KDE-ServiceTypes=KDEDModule, though, fixes the assert but
> shows a blank service entry in the list.
> b) check for file.desktopGroup().readEntry("Hidden", false) just
> before the assert, and continue the loop if so.
> c) use a KServiceTypeTrader query (which hopefully ignores hidden
> desktop files) instead of listing them.
> Even if we say that (a) is the solution for this particular instance,
> it still leaves an unexpected catch in this systemsettings module
> (desktop files here cannot be hidden in the same way as others).  So
> should one of (b) or (c) be implemented also?

c seems the correct solution here. Isn't that what the service type
trader is for anyway?


More information about the kde-core-devel mailing list