Bug 1366808: Properly detect buildID mismatches between parent and child processes and display about:restartrequired to prompt the user to restart Firefox before proceeding. r=jimm,felipe,bz
This commit is contained in:
@@ -4706,6 +4706,16 @@ nsDocShell::DisplayLoadError(nsresult aError, nsIURI* aURI,
|
||||
element->GetAttribute(NS_LITERAL_STRING("crashedPageTitle"), messageStr);
|
||||
}
|
||||
|
||||
// DisplayLoadError requires a non-empty messageStr to proceed and call
|
||||
// LoadErrorPage. If the page doesn't have a title, we will use a blank
|
||||
// space which will be trimmed and thus treated as empty by the front-end.
|
||||
if (messageStr.IsEmpty()) {
|
||||
messageStr.AssignLiteral(u" ");
|
||||
}
|
||||
} else if (NS_ERROR_BUILDID_MISMATCH == aError) {
|
||||
errorPage.AssignLiteral("restartrequired");
|
||||
error = "restartrequired";
|
||||
|
||||
// DisplayLoadError requires a non-empty messageStr to proceed and call
|
||||
// LoadErrorPage. If the page doesn't have a title, we will use a blank
|
||||
// space which will be trimmed and thus treated as empty by the front-end.
|
||||
|
||||
Reference in New Issue
Block a user