From 34e421be7f10496d476266e656ddffe00b42b4e7 Mon Sep 17 00:00:00 2001 From: Christian Persch Date: Sun, 29 Jan 2006 21:44:46 +0000 Subject: If GetPassword failed, break instead of continue. That way we don't 2006-01-29 Christian Persch * embed/mozilla/mozilla-embed-single.cpp: If GetPassword failed, break instead of continue. That way we don't endlessly re-ask for the master password. --- embed/mozilla/mozilla-embed-single.cpp | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'embed/mozilla/mozilla-embed-single.cpp') diff --git a/embed/mozilla/mozilla-embed-single.cpp b/embed/mozilla/mozilla-embed-single.cpp index 0523473a6..e4295ca94 100644 --- a/embed/mozilla/mozilla-embed-single.cpp +++ b/embed/mozilla/mozilla-embed-single.cpp @@ -1067,7 +1067,15 @@ impl_list_passwords (EphyPasswordManager *manager) NS_CSTRING_ENCODING_UTF8, userName); rv = nsPassword->GetPassword (unicodeName); - if (NS_FAILED (rv)) continue; + if (NS_FAILED (rv)) + { + /* this usually means we couldn't decrypt the password, due to + * the master password being unavailable. Don't continue since that + * would lead to endless prompting for the master password; abort + * instead. + */ + break; + } nsEmbedCString userPassword; NS_UTF16ToCString (unicodeName, -- cgit v1.2.3