summaryrefslogtreecommitdiff
blob: 2f5c93898f5be4f61cc4d8a9309e9dadc4ea9834 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
--- kmail/networkaccount.cpp	2008-05-21 10:33:40.000000000 +0200
+++ ../networkaccount.cpp	2009-01-30 12:28:32.032158332 +0100
@@ -205,16 +205,16 @@
 
       //If the password should be written to the wallet, do that
       if ( !mStorePasswdInConfig ) {
-        Wallet *wallet = kmkernel->wallet();
 
         //If the password is dirty, try to store it in the wallet
         if ( mPasswdDirty ) {
+          Wallet *wallet = kmkernel->wallet();
           if ( wallet && wallet->writePassword( "account-" + QString::number(mId), passwd() ) == 0 )
             passwdStored = true;
         }
 
         //If the password isn't dirty, it is already stored in the wallet.
-        else if ( wallet )
+        else
           passwdStored = true;
 
         //If the password is stored in the wallet, it isn't dirty or stored in the config