summaryrefslogtreecommitdiffabout
path: root/microkde/kglobal.cpp
authorulf69 <ulf69>2004-07-02 15:33:56 (UTC)
committer ulf69 <ulf69>2004-07-02 15:33:56 (UTC)
commitbb7ad945c1541684a02e853fdaabd0e3ba74f8df (patch) (side-by-side diff)
tree4ccde1ffdcb3b14cc6ef4945be87a6e82ff174b4 /microkde/kglobal.cpp
parentdf5b4df6bc00ea8acfee0b11a335a9d2f39d04dc (diff)
downloadkdepimpi-bb7ad945c1541684a02e853fdaabd0e3ba74f8df.zip
kdepimpi-bb7ad945c1541684a02e853fdaabd0e3ba74f8df.tar.gz
kdepimpi-bb7ad945c1541684a02e853fdaabd0e3ba74f8df.tar.bz2
removed reentrant solution, for something better
Diffstat (limited to 'microkde/kglobal.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--microkde/kglobal.cpp14
1 files changed, 3 insertions, 11 deletions
diff --git a/microkde/kglobal.cpp b/microkde/kglobal.cpp
index 6fa0dd6..2b1bd34 100644
--- a/microkde/kglobal.cpp
+++ b/microkde/kglobal.cpp
@@ -31,13 +31,3 @@ KConfig *KGlobal::config()
{
- static bool reentrant = false;
-
- if (reentrant)
- return 0;
-
- if ( !mConfig ) {
- reentrant = true;
- mConfig = new KConfig( locateLocal("config", mAppName + "rc" ) );
- reentrant = false;
- }
-
+ //mConfig is set inside setAppName. Though it has to be the first function you call.
return mConfig;
@@ -97,2 +87,4 @@ void KGlobal::setAppName( const QString &appName )
mAppName = appName;
+
+ mConfig = new KConfig( locateLocal("config", mAppName + "rc" ) );
}