Set minimum priority for fast lane connections
[WebKit-https.git] / Source / WebCore / platform / network / cf / ResourceRequestCFNet.cpp
index 6314866..0a0bc7c 100644 (file)
@@ -29,6 +29,7 @@
 #include "ResourceRequest.h"
 
 #if PLATFORM(MAC)
+#include "ResourceLoadPriority.h"
 #include "WebCoreSystemInterface.h"
 #endif
 
@@ -195,6 +196,8 @@ void ResourceRequest::doUpdateResourceRequest()
     m_httpBody = httpBodyFromRequest(m_cfRequest.get());
 }
 
+#if USE(CFURLSTORAGESESSIONS)
+
 void ResourceRequest::setStorageSession(CFURLStorageSessionRef storageSession)
 {
     CFMutableURLRequestRef cfRequest = CFURLRequestCreateMutableCopy(0, m_cfRequest.get());
@@ -202,6 +205,8 @@ void ResourceRequest::setStorageSession(CFURLStorageSessionRef storageSession)
     m_cfRequest.adoptCF(cfRequest);
 }
 
+#endif
+
 #endif // USE(CFNETWORK)
 
 unsigned initializeMaximumHTTPConnectionCountPerHost()
@@ -214,6 +219,8 @@ unsigned initializeMaximumHTTPConnectionCountPerHost()
 
 #if PLATFORM(MAC)
     if (isHTTPPipeliningEnabled()) {
+        wkSetHTTPPipeliningMaximumPriority(ResourceLoadPriorityHighest);
+        wkSetHTTPPipeliningMinimumFastLanePriority(ResourceLoadPriorityMedium);
         // When pipelining do not rate-limit requests sent from WebCore since CFNetwork handles that.
         return unlimitedConnectionCount;
     }