Bug 1650089 - Part 8: Avoid race when calling loadContentPage with about:blank, r=kmag

Without this change, there was a race where the promiseBrowserLoaded promise
from the loadURL call could return early due to observing the load completing
for the default about:blank document, rather than for the second explicit
about:blank load, leading to intermittent timeouts due to loads interrupting
one-another. This change skips the default about:blank document load with
nodefaultsrc, avoiding the issue.

Differential Revision: https://phabricator.services.mozilla.com/D121778
This commit is contained in:
Nika Layzell 2021-08-10 14:31:19 +00:00
Родитель f0aa6596df
Коммит 08996b5877
1 изменённых файлов: 1 добавлений и 0 удалений

Просмотреть файл

@ -185,6 +185,7 @@ class ContentPage {
browser.setAttribute("type", "content");
browser.setAttribute("disableglobalhistory", "true");
browser.setAttribute("messagemanagergroup", "webext-browsers");
browser.setAttribute("nodefaultsrc", "true");
if (this.userContextId) {
browser.setAttribute("usercontextid", this.userContextId);
}