Bug 1279440 - Fix prefetch for rel=next. r=smaug, a=gchang
authorDragana Damjanovic dd.mozilla@gmail.com
Thu, 23 Jun 2016 08:52:00 +0200
changeset 333464 8664ad5c52883cb66cb9b46879eb062fb6600756
parent 333463 96b3e49064c56622c77ff005a1351e9202eecf79
child 333465 2091f8c1a9405f56dfdc8a8b60e25a3dcf97a74a
push id6112
push usercbook@mozilla.com
push dateMon, 27 Jun 2016 12:31:20 +0000
treeherdermozilla-beta@8664ad5c5288 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerssmaug, gchang
bugs1279440
milestone48.0
Bug 1279440 - Fix prefetch for rel=next. r=smaug, a=gchang
dom/base/Link.cpp
--- a/dom/base/Link.cpp
+++ b/dom/base/Link.cpp
@@ -99,17 +99,17 @@ Link::TryDNSPrefetchPreconnectOrPrefetch
       (linkTypes & nsStyleLinkElement::eNEXT)){
     nsCOMPtr<nsIPrefetchService> prefetchService(do_GetService(NS_PREFETCHSERVICE_CONTRACTID));
     if (prefetchService) {
       nsCOMPtr<nsIURI> uri(GetURI());
       if (uri) {
         nsCOMPtr<nsIDOMNode> domNode = GetAsDOMNode(mElement);
         prefetchService->PrefetchURI(uri,
                                      mElement->OwnerDoc()->GetDocumentURI(),
-                                     domNode, true);
+                                     domNode, linkTypes & nsStyleLinkElement::ePREFETCH);
         return;
       }
     }
   }
 
   if (linkTypes & nsStyleLinkElement::ePRECONNECT) {
     nsCOMPtr<nsIURI> uri(GetURI());
     if (uri && mElement->OwnerDoc()) {