Index: kinit.cpp =================================================================== --- kinit/kinit.cpp (revision 829264) +++ kinit/kinit.cpp (revision 828077) @@ -49,10 +49,9 @@ #include #include #include -#include #include #include -#include +#include #include #include #include @@ -530,17 +529,8 @@ if (cwd && *cwd) chdir(cwd); else { - // Can't use KGlobalSettings::documentPath() here, we don't have a main component set, - // and we don't want to set one; e.g. kioslaves will do that. - // So we have to duplicate this stuff from KGlobalSettings. - KConfigGroup g(s_instance->config(), "Paths"); - const QString documentPath = g.readPathEntry("Documents", -#ifdef Q_WS_WIN - getWin32ShellFoldersPath("Personal") -#else - QDir::homePath()); -#endif - const QByteArray docPath = QFile::encodeName(documentPath); + KComponentData componentData("klauncher"); // needed for KConfig usage + const QByteArray docPath = QFile::encodeName(KGlobalSettings::documentPath()); chdir(docPath.constData()); }