[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-core-devel
Subject:    Re: KWalletd crashing on cvs head
From:       Richard Smith <kde () metafoo ! co ! uk>
Date:       2004-11-27 13:16:20
Message-ID: 200411271316.20793.kde () metafoo ! co ! uk
[Download RAW message or body]

On Saturday 27 November 2004 12:44, Anders Lund wrote:
> On Saturday 27 November 2004 12:37, Thomas Vollmer wrote:
> > On Thursday 25 November 2004 11:59, Andrew Coles wrote:
> > > On Thursday 25 Nov 2004 08:36, Helge Deller wrote:
> > > > On Thursday 25 November 2004 07:40, Ismail Donmez wrote:
> > > > > Looks like latest kpassworddialog changes borked KWalletd somehow
> > > > > ( just guessing from a useless backtrace ;) ) . Wonder if anyone
> > > > > noticed it?
> > > >
> > > > I see the crashes as well.
> > >
> > > OK, tell me how to reproduce it off-the-list and I'll look into it.
> > > In theory at least, they shouldn't have made a difference unless
> > > KWallet is using the new calls though.
> >
> > Is there any progress on this? For me my kded crashes immediately after I
> > entered the password for opening a wallet.
>
> I had the same problem yesterday, and was adviced to downgrade
> kdelibs/kdeui/kpassdlg.*. I selected kpassdlg.cpp 1.39 and the
> corresponding .h file (1.41 i think), and after rebuilding kdeui,
> everything works.

The attached patch to kpassdlg.cpp fixes this. OK to commit?
-- 
Thanks,
Richard

["kpassdlg-dontCrash.diff" (text/x-diff)]

Index: kpassdlg.cpp
===================================================================
RCS file: /home/kde/kdelibs/kdeui/kpassdlg.cpp,v
retrieving revision 1.42
diff -u -3 -p -r1.42 kpassdlg.cpp
--- kpassdlg.cpp	25 Nov 2004 21:54:07 -0000	1.42
+++ kpassdlg.cpp	27 Nov 2004 13:03:49 -0000
@@ -86,7 +86,7 @@ class KPasswordDialog::KPasswordDialogPr
 	KPasswordDialogPrivate()
 	 : m_MatchLabel( 0 ), iconName( 0 ), allowEmptyPasswords( false ),
 	   minimumPasswordLength(0), maximumPasswordLength(KPasswordEdit::PassLen - 1),
-	   passwordStrengthWarningLevel(1)
+	   passwordStrengthWarningLevel(1), m_strengthBar(0)
 	    {}
 	QLabel *m_MatchLabel;
 	QString iconName;
@@ -511,10 +511,9 @@ void KPasswordDialog::slotOk()
 	    erase();
 	    return;
 	}
-    }
-    if (d->m_strengthBar->progress() < d->passwordStrengthWarningLevel) {
-	int retVal = KMessageBox::warningYesNo(this,
-		i18n(	"The password you have entered has a low strength. "
+	if (d->m_strengthBar && d->m_strengthBar->progress() < d->passwordStrengthWarningLevel) {
+	    int retVal = KMessageBox::warningYesNo(this,
+		i18n(   "The password you have entered has a low strength. "
 			"To improve the strength of "
 			"the password, try:\n"
 			" - using a longer password;\n"
@@ -523,7 +522,8 @@ void KPasswordDialog::slotOk()
 			"\n"
 			"Would you like to use this password anyway?"),
 		i18n("Low Password Strength"));
-	if (retVal == KMessageBox::No) return;
+	    if (retVal == KMessageBox::No) return;
+	}
     }
     if (!checkPassword(m_pEdit->password())) {
 	erase();


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic