IDEA-64945 Don't show master password prompt if the master password is empty

This commit is contained in:
Kirill Likhodedov
2012-03-25 15:19:28 +04:00
parent 4730a6a22f
commit 81ddca9aad
@@ -104,6 +104,11 @@ public class MasterPasswordDialog extends DialogWrapper {
* @throws PasswordSafeException if the master password is not provided.
*/
public static void askPassword(Project project, MasterKeyPasswordSafe safe) throws PasswordSafeException {
// trying empty password: people who have set up empty password, don't want to get disturbed by the prompt.
if (safe.setMasterPassword("")) {
return;
}
String error = null;
retries:
for (int count = 0; count < NUMBER_OF_RETRIES; count++) {