Diff
Modified: trunk/Source/WebCore/ChangeLog (227206 => 227207)
--- trunk/Source/WebCore/ChangeLog 2018-01-19 17:48:23 UTC (rev 227206)
+++ trunk/Source/WebCore/ChangeLog 2018-01-19 17:55:55 UTC (rev 227207)
@@ -1,5 +1,26 @@
2018-01-19 Alex Christensen <[email protected]>
+ Remove dead networking code
+ https://bugs.webkit.org/show_bug.cgi?id=181813
+
+ Reviewed by Tim Horton.
+
+ CFURLConnection is only used on Windows.
+
+ * platform/network/cf/ResourceError.h:
+ * platform/network/cf/ResourceRequest.h:
+ (WebCore::ResourceRequest::encodingRequiresPlatformData const):
+ * platform/network/cf/ResourceRequestCFNet.cpp:
+ (WebCore::findCFURLRequestCopyContentDispositionEncodingFallbackArrayFunction):
+ (WebCore::ResourceRequest::doUpdatePlatformRequest):
+ (WebCore::ResourceRequest::doUpdatePlatformHTTPBody):
+ (WebCore::ResourceRequest::doUpdateResourceRequest):
+ (WebCore::ResourceRequest::setStorageSession):
+ * platform/network/cf/ResourceResponse.h:
+ (WebCore::ResourceResponse::ResourceResponse):
+
+2018-01-19 Alex Christensen <[email protected]>
+
Remove unused WebViewPrivate _allowCookies
https://bugs.webkit.org/show_bug.cgi?id=181812
Modified: trunk/Source/WebCore/platform/network/cf/ResourceError.h (227206 => 227207)
--- trunk/Source/WebCore/platform/network/cf/ResourceError.h 2018-01-19 17:48:23 UTC (rev 227206)
+++ trunk/Source/WebCore/platform/network/cf/ResourceError.h 2018-01-19 17:55:55 UTC (rev 227207)
@@ -62,11 +62,9 @@
WEBCORE_EXPORT operator CFErrorRef() const;
#if USE(CFURLCONNECTION)
-#if PLATFORM(WIN)
ResourceError(const String& domain, int errorCode, const URL& failingURL, const String& localizedDescription, CFDataRef certificate);
PCCERT_CONTEXT certificate() const;
void setCertificate(CFDataRef);
-#endif
ResourceError(CFStreamError error);
CFStreamError cfStreamError() const;
operator CFStreamError() const;
@@ -90,9 +88,6 @@
bool m_dataIsUpToDate;
#if USE(CFURLCONNECTION)
mutable RetainPtr<CFErrorRef> m_platformError;
-#if PLATFORM(COCOA)
- mutable RetainPtr<NSError> m_platformNSError;
-#endif
#if PLATFORM(WIN)
RetainPtr<CFDataRef> m_certificate;
#endif
Modified: trunk/Source/WebCore/platform/network/cf/ResourceRequest.h (227206 => 227207)
--- trunk/Source/WebCore/platform/network/cf/ResourceRequest.h 2018-01-19 17:48:23 UTC (rev 227206)
+++ trunk/Source/WebCore/platform/network/cf/ResourceRequest.h 2018-01-19 17:55:55 UTC (rev 227207)
@@ -63,12 +63,6 @@
}
#if USE(CFURLCONNECTION)
-#if PLATFORM(COCOA)
- WEBCORE_EXPORT ResourceRequest(NSURLRequest *);
- void updateNSURLRequest();
- void clearOrUpdateNSURLRequest();
-#endif
-
ResourceRequest(CFURLRequestRef cfRequest)
: ResourceRequestBase()
, m_cfRequest(cfRequest)
@@ -85,11 +79,7 @@
WEBCORE_EXPORT void updateFromDelegatePreservingOldProperties(const ResourceRequest&);
#if PLATFORM(COCOA)
-#if USE(CFURLCONNECTION)
- bool encodingRequiresPlatformData() const { return m_httpBody || m_cfRequest; }
-#else
bool encodingRequiresPlatformData() const { return m_httpBody || m_nsRequest; }
-#endif
WEBCORE_EXPORT NSURLRequest *nsURLRequest(HTTPBodyUpdatePolicy) const;
WEBCORE_EXPORT static CFStringRef isUserInitiatedKey();
Modified: trunk/Source/WebCore/platform/network/cf/ResourceRequestCFNet.cpp (227206 => 227207)
--- trunk/Source/WebCore/platform/network/cf/ResourceRequestCFNet.cpp 2018-01-19 17:48:23 UTC (rev 227206)
+++ trunk/Source/WebCore/platform/network/cf/ResourceRequestCFNet.cpp 2018-01-19 17:55:55 UTC (rev 227207)
@@ -82,16 +82,6 @@
{
return reinterpret_cast<CFURLRequestCopyContentDispositionEncodingFallbackArrayFunction>(GetProcAddress(findCFNetworkModule(), "_CFURLRequestCopyContentDispositionEncodingFallbackArray"));
}
-#elif PLATFORM(COCOA)
-static CFURLRequestSetContentDispositionEncodingFallbackArrayFunction findCFURLRequestSetContentDispositionEncodingFallbackArrayFunction()
-{
- return reinterpret_cast<CFURLRequestSetContentDispositionEncodingFallbackArrayFunction>(dlsym(RTLD_DEFAULT, "_CFURLRequestSetContentDispositionEncodingFallbackArray"));
-}
-
-static CFURLRequestCopyContentDispositionEncodingFallbackArrayFunction findCFURLRequestCopyContentDispositionEncodingFallbackArrayFunction()
-{
- return reinterpret_cast<CFURLRequestCopyContentDispositionEncodingFallbackArrayFunction>(dlsym(RTLD_DEFAULT, "_CFURLRequestCopyContentDispositionEncodingFallbackArray"));
-}
#endif
static void setContentDispositionEncodingFallbackArray(CFMutableURLRequestRef request, CFArrayRef fallbackArray)
@@ -175,10 +165,6 @@
if (resourcePrioritiesEnabled())
CFURLRequestSetRequestPriority(cfRequest, toPlatformRequestPriority(priority()));
-#if !PLATFORM(WIN)
- _CFURLRequestSetProtocolProperty(cfRequest, kCFURLRequestAllowAllPOSTCaching, kCFBooleanTrue);
-#endif
-
setHeaderFields(cfRequest, httpHeaderFields());
CFURLRequestSetShouldHandleHTTPCookies(cfRequest, allowCookies());
@@ -203,9 +189,6 @@
#endif
m_cfRequest = adoptCF(cfRequest);
-#if PLATFORM(COCOA)
- clearOrUpdateNSURLRequest();
-#endif
}
void ResourceRequest::doUpdatePlatformHTTPBody()
@@ -239,30 +222,12 @@
}
m_cfRequest = adoptCF(cfRequest);
-#if PLATFORM(COCOA)
- clearOrUpdateNSURLRequest();
-#endif
}
void ResourceRequest::doUpdateResourceRequest()
{
if (!m_cfRequest) {
-#if PLATFORM(IOS)
- // <rdar://problem/9913526>
- // This is a hack to mimic the subtle behaviour of the Foundation based ResourceRequest
- // code. That code does not reset m_httpMethod if the NSURLRequest is nil. I filed
- // <https://bugs.webkit.org/show_bug.cgi?id=66336> to track that.
- // Another related bug is <https://bugs.webkit.org/show_bug.cgi?id=66350>. Fixing that
- // would, ideally, allow us to not have this hack. But unfortunately that caused layout test
- // failures.
- // Removal of this hack is tracked by <rdar://problem/9970499>.
-
- String httpMethod = m_httpMethod;
*this = ResourceRequest();
- m_httpMethod = httpMethod;
-#else
- *this = ResourceRequest();
-#endif
return;
}
@@ -338,9 +303,6 @@
if (storageSession)
_CFURLRequestSetStorageSession(cfRequest, storageSession);
m_cfRequest = adoptCF(cfRequest);
-#if PLATFORM(COCOA)
- clearOrUpdateNSURLRequest();
-#endif
}
#endif // USE(CFURLCONNECTION)
Modified: trunk/Source/WebCore/platform/network/cf/ResourceResponse.h (227206 => 227207)
--- trunk/Source/WebCore/platform/network/cf/ResourceResponse.h 2018-01-19 17:48:23 UTC (rev 227206)
+++ trunk/Source/WebCore/platform/network/cf/ResourceResponse.h 2018-01-19 17:55:55 UTC (rev 227207)
@@ -50,9 +50,6 @@
{
m_isNull = !cfResponse;
}
-#if PLATFORM(COCOA)
- WEBCORE_EXPORT ResourceResponse(NSURLResponse *);
-#endif
#else
ResourceResponse(NSURLResponse *nsResponse)
: m_initLevel(Uninitialized)