summaryrefslogtreecommitdiffstats
path: root/netwerk/protocol
diff options
context:
space:
mode:
authorwolfbeast <mcwerewolf@gmail.com>2018-12-14 12:50:01 +0100
committerwolfbeast <mcwerewolf@gmail.com>2018-12-14 12:50:01 +0100
commitfea96b4527a2db6cd97c9053d647478b347d3853 (patch)
treeeeb73acd7f8295dbab17ec993392bce3161be9db /netwerk/protocol
parent2e69b03ddd11de777e6d52a995ff0d1675eb58d2 (diff)
downloadUXP-fea96b4527a2db6cd97c9053d647478b347d3853.tar
UXP-fea96b4527a2db6cd97c9053d647478b347d3853.tar.gz
UXP-fea96b4527a2db6cd97c9053d647478b347d3853.tar.lz
UXP-fea96b4527a2db6cd97c9053d647478b347d3853.tar.xz
UXP-fea96b4527a2db6cd97c9053d647478b347d3853.zip
Do not report resource-timing subdocument loads triggered by that subdocument.
Diffstat (limited to 'netwerk/protocol')
-rw-r--r--netwerk/protocol/http/HttpBaseChannel.cpp11
1 files changed, 7 insertions, 4 deletions
diff --git a/netwerk/protocol/http/HttpBaseChannel.cpp b/netwerk/protocol/http/HttpBaseChannel.cpp
index 03123ceb0..21b661c2b 100644
--- a/netwerk/protocol/http/HttpBaseChannel.cpp
+++ b/netwerk/protocol/http/HttpBaseChannel.cpp
@@ -3676,14 +3676,17 @@ HttpBaseChannel::GetPerformance()
return nullptr;
}
- // We only add to the document's performance object if it has the same
- // principal as the one triggering the load. This is to prevent navigations
- // triggered _by_ the iframe from showing up in the parent document's
- // performance entries if they have different origins.
if (!mLoadInfo->TriggeringPrincipal()->Equals(loadingDocument->NodePrincipal())) {
return nullptr;
}
+ if (mLoadInfo->GetExternalContentPolicyType() == nsIContentPolicy::TYPE_SUBDOCUMENT &&
+ !mLoadInfo->GetIsFromProcessingFrameAttributes()) {
+ // We only report loads caused by processing the attributes of the
+ // browsing context container.
+ return nullptr;
+ }
+
nsCOMPtr<nsPIDOMWindowInner> innerWindow = loadingDocument->GetInnerWindow();
if (!innerWindow) {
return nullptr;