mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-30 08:12:05 +00:00
last touches to finally get Cancel (from the Create Profile Wizard) and Exit
(from the Profile Manager) to work properly.
This commit is contained in:
parent
e8fb6b9150
commit
cca4758400
@ -334,6 +334,16 @@ nsProfile::LoadDefaultProfileDir(nsCString & profileURLStr)
|
||||
rv = profAppShell->Run();
|
||||
}
|
||||
|
||||
// if we get here, and we don't have a current profile,
|
||||
// return a failure so we will exit
|
||||
// this can happen, if the user hits Exit in the profile manager dialog
|
||||
char *currentProfileStr = nsnull;
|
||||
rv = GetCurrentProfile(¤tProfileStr);
|
||||
if (NS_FAILED(rv) || !currentProfileStr || (PL_strlen(currentProfileStr) == 0)) {
|
||||
return NS_ERROR_FAILURE;
|
||||
}
|
||||
PR_FREEIF(currentProfileStr);
|
||||
|
||||
if (pregPref && PL_strcmp(isPregInfoSet, REGISTRY_TRUE_STRING) != 0)
|
||||
ProcessPRegCookie();
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user