Closed Bug 1395948 Opened 5 years ago Closed 5 years ago
top level data: url loading blocking happens too late
In case we're about to open a new window, http://searchfox.org/mozilla-central/rev/51b3d67a5ec1758bd2fe7d7b6e75ad6b6b5da223/docshell/base/nsDocShell.cpp#11109 is too late. The new window has been opened already. We need to block earlier, somewhere close to http://searchfox.org/mozilla-central/rev/51b3d67a5ec1758bd2fe7d7b6e75ad6b6b5da223/docshell/base/nsDocShell.cpp#9931
Assignee: nobody → ckerschb
Status: NEW → ASSIGNED
Priority: -- → P2
Comment on attachment 8904332 [details] [diff] [review] bug_1395948_data_block_too_late.patch Would be nice to have a test for this, especially given that we didn't catch this issue earlier.
Attachment #8904332 - Flags: review?(bugs) → review+
(In reply to Olli Pettay [:smaug] from comment #2) > Would be nice to have a test for this, especially given that we didn't catch > this issue earlier. Well, we have: * browser_test_toplevel_data_navigations.js * test_block_toplevel_data_navigation.html but I agree that those tests are not explicitly about checking whether the window itself got created. I filed Bug 1396749 to think about all the different use cases again.
Pushed by email@example.com: https://hg.mozilla.org/integration/mozilla-inbound/rev/4270e8daf3cf Move blocking of toplevel data: URI navigations before opening a new window. r=smaug
Backed out for build bustage at docshell/base/nsDocShellLoadTypes.h:22: https://hg.mozilla.org/integration/mozilla-inbound/rev/cedbffc70de59f2b4fba0d6ba904ab04c50419e8 Push with bustage: https://treeherder.mozilla.org/#/jobs?repo=mozilla-inbound&revision=4270e8daf3cfa04746f27e64847c7edfcda1e0f8&filter-resultStatus=testfailed&filter-resultStatus=busted&filter-resultStatus=exception&filter-resultStatus=retry&filter-resultStatus=usercancel&filter-resultStatus=runnable Build log: https://treeherder.mozilla.org/logviewer.html#?job_id=128468527&repo=mozilla-inbound > /builds/worker/workspace/build/src/docshell/base/nsDocShellLoadTypes.h:22:61: error: result of '(268435457 << 16)' requires 46 bits to represent, but 'int' only has 32 bits [-Werror=shift-overflow=]
(In reply to Sebastian Hengst [:aryx][:archaeopteryx] (needinfo on intermittent or backout) from comment #5) > Backed out for build bustage at docshell/base/nsDocShellLoadTypes.h:22: Ah, this is an enum, so we can simply do: bool loadFromExternal = (aLoadType == LOAD_NORMAL_EXTERNAL); like we do elsewhere within nsDocshell.
Pushed by firstname.lastname@example.org: https://hg.mozilla.org/integration/mozilla-inbound/rev/74d087bee9e5 Move blocking of toplevel data: URI navigations before opening a new window. r=smaug
You need to log in before you can comment on or make changes to this bug.