From f050e5628e825e6f8dc74dc66989de17c7a3b757 Mon Sep 17 00:00:00 2001 From: David Faure Date: Mon, 5 Feb 2007 22:27:25 +0000 Subject: [PATCH] When not using kwallet, kmail can store the smtp password into kmailrc, which works, but for every mail sent after that it asked again: do you want to store the password into the config file? -> fixed svn path=/trunk/KDE/kdepim/; revision=630634 --- kmtransport.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/kmtransport.cpp b/kmtransport.cpp index 63627407b..589edb9a8 100644 --- a/kmtransport.cpp +++ b/kmtransport.cpp @@ -130,15 +130,15 @@ void KMTransportInfo::writeConfig(int id) if ( storePasswd() ) { // write password into the wallet if possible and necessary bool passwdStored = false; + Wallet *wallet = kmkernel->wallet(); if ( mPasswdDirty ) { - Wallet *wallet = kmkernel->wallet(); if ( wallet && wallet->writePassword( "transport-" + QString::number(mId), passwd() ) == 0 ) { passwdStored = true; mPasswdDirty = false; mStorePasswdInConfig = false; } } else { - passwdStored = !mStorePasswdInConfig; // already in the wallet + passwdStored = wallet ? !mStorePasswdInConfig /*already in the wallet*/ : config->hasKey("pass"); } // wallet not available, ask the user if we should use the config file instead if ( !passwdStored && ( mStorePasswdInConfig || KMessageBox::warningYesNo( 0,