<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[201623] trunk/Source/WebCore</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.webkit.org/projects/webkit/changeset/201623">201623</a></dd>
<dt>Author</dt> <dd>beidson@apple.com</dd>
<dt>Date</dt> <dd>2016-06-02 15:43:25 -0700 (Thu, 02 Jun 2016)</dd>
</dl>

<h3>Log Message</h3>
<pre>Modernize how many platform/network classes do isolatedCopy().
https://bugs.webkit.org/show_bug.cgi?id=158313

Reviewed by Alex Christensen.

No new tests (Refactor, no behavior change).

* loader/WorkerThreadableLoader.h:

* platform/network/FormData.cpp:
(WebCore::FormData::isolatedCopy):
(WebCore::FormDataElement::isolatedCopy):
(WebCore::FormData::FormData): Deleted.
(WebCore::FormData::deepCopy): Deleted.
* platform/network/FormData.h:

* platform/network/HTTPHeaderMap.cpp:
(WebCore::HTTPHeaderMap::isolatedCopy):
(WebCore::HTTPHeaderMap::copyData): Deleted.
(WebCore::HTTPHeaderMap::adopt): Deleted.
* platform/network/HTTPHeaderMap.h:

* platform/network/ResourceErrorBase.cpp:
(WebCore::ResourceErrorBase::asResourceError):
(WebCore::ResourceErrorBase::isolatedCopy):
* platform/network/ResourceErrorBase.h:
(WebCore::ResourceErrorBase::platformCopy): Deleted.

* platform/network/ResourceLoadTiming.h:
(WebCore::ResourceLoadTiming::isolatedCopy): Not strictly needed for now, but makes it obvious
  that changes will be needed if new members are added later.

* platform/network/ResourceRequestBase.cpp:
(WebCore::ResourceRequestBase::isolatedCopy):
(WebCore::ResourceRequestBase::setAsIsolatedCopy):
(WebCore::ResourceRequestBase::copyData): Deleted.
* platform/network/ResourceRequestBase.h:

* platform/network/ResourceResponseBase.cpp:
(WebCore::ResourceResponseBase::isolatedCopy):
(WebCore::ResourceResponseBase::copyData): Deleted.
* platform/network/ResourceResponseBase.h:
(WebCore::CrossThreadResourceResponseDataBase::CrossThreadResourceResponseDataBase): Deleted.

* platform/network/cf/ResourceError.h:
* platform/network/cf/ResourceErrorCF.cpp:
(WebCore::ResourceError::doPlatformIsolatedCopy):
(WebCore::ResourceError::platformCopy): Deleted.

* platform/network/cf/ResourceRequest.h:
* platform/network/cf/ResourceRequestCFNet.cpp:
(WebCore::ResourceRequest::doPlatformSetAsIsolatedCopy):
(WebCore::ResourceRequest::doPlatformCopyData): Deleted.
(WebCore::ResourceRequest::doPlatformAdopt): Deleted.

* platform/network/cf/ResourceResponse.h:
(WebCore::ResourceResponse::doPlatformCopyData): Deleted.
(WebCore::ResourceResponse::doPlatformAdopt): Deleted.

* platform/network/curl/ResourceError.h:
(WebCore::ResourceError::doPlatformIsolatedCopy):

* platform/network/curl/ResourceRequest.h:
(WebCore::ResourceRequest::doPlatformSetAsIsolatedCopy):
(WebCore::ResourceRequest::doPlatformCopyData): Deleted.
(WebCore::ResourceRequest::doPlatformAdopt): Deleted.

* platform/network/curl/ResourceResponse.h:
(WebCore::ResourceResponse::doPlatformCopyData): Deleted.
(WebCore::ResourceResponse::doPlatformAdopt): Deleted.

* platform/network/mac/ResourceErrorMac.mm:
(WebCore::ResourceError::doPlatformIsolatedCopy):

* platform/network/soup/ResourceError.h:
* platform/network/soup/ResourceErrorSoup.cpp:
(WebCore::ResourceError::doPlatformIsolatedCopy):
(WebCore::ResourceError::platformCopy): Deleted.

* platform/network/soup/ResourceRequest.h:
(WebCore::ResourceRequest::doPlatformSetAsIsolatedCopy):
(WebCore::ResourceRequest::doPlatformCopyData): Deleted.
(WebCore::ResourceRequest::doPlatformAdopt): Deleted.

* platform/network/soup/ResourceResponse.h:
(WebCore::ResourceResponse::doPlatformCopyData): Deleted.
(WebCore::ResourceResponse::doPlatformAdopt): Deleted.</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkSourceWebCoreChangeLog">trunk/Source/WebCore/ChangeLog</a></li>
<li><a href="#trunkSourceWebCoreloaderWorkerThreadableLoaderh">trunk/Source/WebCore/loader/WorkerThreadableLoader.h</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworkFormDatacpp">trunk/Source/WebCore/platform/network/FormData.cpp</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworkFormDatah">trunk/Source/WebCore/platform/network/FormData.h</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworkHTTPHeaderMapcpp">trunk/Source/WebCore/platform/network/HTTPHeaderMap.cpp</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworkHTTPHeaderMaph">trunk/Source/WebCore/platform/network/HTTPHeaderMap.h</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworkResourceErrorBasecpp">trunk/Source/WebCore/platform/network/ResourceErrorBase.cpp</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworkResourceErrorBaseh">trunk/Source/WebCore/platform/network/ResourceErrorBase.h</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworkResourceLoadTimingh">trunk/Source/WebCore/platform/network/ResourceLoadTiming.h</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworkResourceRequestBasecpp">trunk/Source/WebCore/platform/network/ResourceRequestBase.cpp</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworkResourceRequestBaseh">trunk/Source/WebCore/platform/network/ResourceRequestBase.h</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworkResourceResponseBasecpp">trunk/Source/WebCore/platform/network/ResourceResponseBase.cpp</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworkResourceResponseBaseh">trunk/Source/WebCore/platform/network/ResourceResponseBase.h</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworkcfResourceErrorh">trunk/Source/WebCore/platform/network/cf/ResourceError.h</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworkcfResourceErrorCFcpp">trunk/Source/WebCore/platform/network/cf/ResourceErrorCF.cpp</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworkcfResourceRequesth">trunk/Source/WebCore/platform/network/cf/ResourceRequest.h</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworkcfResourceRequestCFNetcpp">trunk/Source/WebCore/platform/network/cf/ResourceRequestCFNet.cpp</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworkcfResourceResponseh">trunk/Source/WebCore/platform/network/cf/ResourceResponse.h</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworkcurlResourceErrorh">trunk/Source/WebCore/platform/network/curl/ResourceError.h</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworkcurlResourceRequesth">trunk/Source/WebCore/platform/network/curl/ResourceRequest.h</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworkcurlResourceResponseh">trunk/Source/WebCore/platform/network/curl/ResourceResponse.h</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworkmacResourceErrorMacmm">trunk/Source/WebCore/platform/network/mac/ResourceErrorMac.mm</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworksoupResourceErrorh">trunk/Source/WebCore/platform/network/soup/ResourceError.h</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworksoupResourceErrorSoupcpp">trunk/Source/WebCore/platform/network/soup/ResourceErrorSoup.cpp</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworksoupResourceRequesth">trunk/Source/WebCore/platform/network/soup/ResourceRequest.h</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworksoupResourceResponseh">trunk/Source/WebCore/platform/network/soup/ResourceResponse.h</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/ChangeLog (201622 => 201623)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/ChangeLog        2016-06-02 22:18:27 UTC (rev 201622)
+++ trunk/Source/WebCore/ChangeLog        2016-06-02 22:43:25 UTC (rev 201623)
</span><span class="lines">@@ -1,3 +1,93 @@
</span><ins>+2016-06-02  Brady Eidson  &lt;beidson@apple.com&gt;
+
+        Modernize how many platform/network classes do isolatedCopy().
+        https://bugs.webkit.org/show_bug.cgi?id=158313
+
+        Reviewed by Alex Christensen.
+
+        No new tests (Refactor, no behavior change).
+
+        * loader/WorkerThreadableLoader.h:
+        
+        * platform/network/FormData.cpp:
+        (WebCore::FormData::isolatedCopy):
+        (WebCore::FormDataElement::isolatedCopy):
+        (WebCore::FormData::FormData): Deleted.
+        (WebCore::FormData::deepCopy): Deleted.
+        * platform/network/FormData.h:
+        
+        * platform/network/HTTPHeaderMap.cpp:
+        (WebCore::HTTPHeaderMap::isolatedCopy):
+        (WebCore::HTTPHeaderMap::copyData): Deleted.
+        (WebCore::HTTPHeaderMap::adopt): Deleted.
+        * platform/network/HTTPHeaderMap.h:
+        
+        * platform/network/ResourceErrorBase.cpp:
+        (WebCore::ResourceErrorBase::asResourceError):
+        (WebCore::ResourceErrorBase::isolatedCopy):
+        * platform/network/ResourceErrorBase.h:
+        (WebCore::ResourceErrorBase::platformCopy): Deleted.
+
+        * platform/network/ResourceLoadTiming.h:
+        (WebCore::ResourceLoadTiming::isolatedCopy): Not strictly needed for now, but makes it obvious
+          that changes will be needed if new members are added later.
+
+        * platform/network/ResourceRequestBase.cpp:
+        (WebCore::ResourceRequestBase::isolatedCopy):
+        (WebCore::ResourceRequestBase::setAsIsolatedCopy):
+        (WebCore::ResourceRequestBase::copyData): Deleted.
+        * platform/network/ResourceRequestBase.h:
+        
+        * platform/network/ResourceResponseBase.cpp:
+        (WebCore::ResourceResponseBase::isolatedCopy):
+        (WebCore::ResourceResponseBase::copyData): Deleted.
+        * platform/network/ResourceResponseBase.h:
+        (WebCore::CrossThreadResourceResponseDataBase::CrossThreadResourceResponseDataBase): Deleted.
+        
+        * platform/network/cf/ResourceError.h:
+        * platform/network/cf/ResourceErrorCF.cpp:
+        (WebCore::ResourceError::doPlatformIsolatedCopy):
+        (WebCore::ResourceError::platformCopy): Deleted.
+        
+        * platform/network/cf/ResourceRequest.h:
+        * platform/network/cf/ResourceRequestCFNet.cpp:
+        (WebCore::ResourceRequest::doPlatformSetAsIsolatedCopy):
+        (WebCore::ResourceRequest::doPlatformCopyData): Deleted.
+        (WebCore::ResourceRequest::doPlatformAdopt): Deleted.
+        
+        * platform/network/cf/ResourceResponse.h:
+        (WebCore::ResourceResponse::doPlatformCopyData): Deleted.
+        (WebCore::ResourceResponse::doPlatformAdopt): Deleted.
+        
+        * platform/network/curl/ResourceError.h:
+        (WebCore::ResourceError::doPlatformIsolatedCopy):
+        
+        * platform/network/curl/ResourceRequest.h:
+        (WebCore::ResourceRequest::doPlatformSetAsIsolatedCopy):
+        (WebCore::ResourceRequest::doPlatformCopyData): Deleted.
+        (WebCore::ResourceRequest::doPlatformAdopt): Deleted.
+        
+        * platform/network/curl/ResourceResponse.h:
+        (WebCore::ResourceResponse::doPlatformCopyData): Deleted.
+        (WebCore::ResourceResponse::doPlatformAdopt): Deleted.
+        
+        * platform/network/mac/ResourceErrorMac.mm:
+        (WebCore::ResourceError::doPlatformIsolatedCopy):
+        
+        * platform/network/soup/ResourceError.h:
+        * platform/network/soup/ResourceErrorSoup.cpp:
+        (WebCore::ResourceError::doPlatformIsolatedCopy):
+        (WebCore::ResourceError::platformCopy): Deleted.
+        
+        * platform/network/soup/ResourceRequest.h:
+        (WebCore::ResourceRequest::doPlatformSetAsIsolatedCopy):
+        (WebCore::ResourceRequest::doPlatformCopyData): Deleted.
+        (WebCore::ResourceRequest::doPlatformAdopt): Deleted.
+        
+        * platform/network/soup/ResourceResponse.h:
+        (WebCore::ResourceResponse::doPlatformCopyData): Deleted.
+        (WebCore::ResourceResponse::doPlatformAdopt): Deleted.
+
</ins><span class="cx"> 2016-06-02  Chris Dumez  &lt;cdumez@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         Crash under CachedResource::addClientToSet()
</span></span></pre></div>
<a id="trunkSourceWebCoreloaderWorkerThreadableLoaderh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/loader/WorkerThreadableLoader.h (201622 => 201623)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/loader/WorkerThreadableLoader.h        2016-06-02 22:18:27 UTC (rev 201622)
+++ trunk/Source/WebCore/loader/WorkerThreadableLoader.h        2016-06-02 22:43:25 UTC (rev 201623)
</span><span class="lines">@@ -45,8 +45,6 @@
</span><span class="cx">     class ResourceRequest;
</span><span class="cx">     class WorkerGlobalScope;
</span><span class="cx">     class WorkerLoaderProxy;
</span><del>-    struct CrossThreadResourceResponseData;
-    struct CrossThreadResourceRequestData;
</del><span class="cx"> 
</span><span class="cx">     class WorkerThreadableLoader : public RefCounted&lt;WorkerThreadableLoader&gt;, public ThreadableLoader {
</span><span class="cx">         WTF_MAKE_FAST_ALLOCATED;
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworkFormDatacpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/FormData.cpp (201622 => 201623)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/FormData.cpp        2016-06-02 22:18:27 UTC (rev 201622)
+++ trunk/Source/WebCore/platform/network/FormData.cpp        2016-06-02 22:43:25 UTC (rev 201623)
</span><span class="lines">@@ -39,9 +39,6 @@
</span><span class="cx"> namespace WebCore {
</span><span class="cx"> 
</span><span class="cx"> inline FormData::FormData()
</span><del>-    : m_identifier(0)
-    , m_alwaysStream(false)
-    , m_containsPasswordData(false)
</del><span class="cx"> {
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="lines">@@ -115,29 +112,34 @@
</span><span class="cx">     return adoptRef(*new FormData(*this));
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-Ref&lt;FormData&gt; FormData::deepCopy() const
</del><ins>+Ref&lt;FormData&gt; FormData::isolatedCopy() const
</ins><span class="cx"> {
</span><del>-    Ref&lt;FormData&gt; formData(create());
</del><ins>+    // FIXME: isolatedCopy() (historically deepCopy()) only copies certain values from `this`. Why is that?
+    auto formData = create();
</ins><span class="cx"> 
</span><span class="cx">     formData-&gt;m_alwaysStream = m_alwaysStream;
</span><span class="cx"> 
</span><span class="cx">     formData-&gt;m_elements.reserveInitialCapacity(m_elements.size());
</span><del>-    for (const FormDataElement&amp; element : m_elements) {
-        switch (element.m_type) {
-        case FormDataElement::Type::Data:
-            formData-&gt;m_elements.uncheckedAppend(FormDataElement(element.m_data));
-            break;
-        case FormDataElement::Type::EncodedFile:
-            formData-&gt;m_elements.uncheckedAppend(FormDataElement(element.m_filename, element.m_fileStart, element.m_fileLength, element.m_expectedFileModificationTime, element.m_shouldGenerateFile));
-            break;
-        case FormDataElement::Type::EncodedBlob:
-            formData-&gt;m_elements.uncheckedAppend(FormDataElement(element.m_url));
-            break;
-        }
-    }
</del><ins>+    for (auto&amp; element : m_elements)
+        formData-&gt;m_elements.uncheckedAppend(element.isolatedCopy());
+
</ins><span class="cx">     return formData;
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+FormDataElement FormDataElement::isolatedCopy() const
+{
+    switch (m_type) {
+    case Type::Data:
+        return FormDataElement(m_data);
+    case Type::EncodedFile:
+        return FormDataElement(m_filename.isolatedCopy(), m_fileStart, m_fileLength, m_expectedFileModificationTime, m_shouldGenerateFile);
+    case Type::EncodedBlob:
+        return FormDataElement(m_url.isolatedCopy());
+    }
+
+    RELEASE_ASSERT_NOT_REACHED();
+}
+
</ins><span class="cx"> void FormData::appendData(const void* data, size_t size)
</span><span class="cx"> {
</span><span class="cx">     memcpy(expandDataStore(size), data, size);
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworkFormDatah"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/FormData.h (201622 => 201623)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/FormData.h        2016-06-02 22:18:27 UTC (rev 201622)
+++ trunk/Source/WebCore/platform/network/FormData.h        2016-06-02 22:43:25 UTC (rev 201623)
</span><span class="lines">@@ -69,6 +69,8 @@
</span><span class="cx">     {
</span><span class="cx">     }
</span><span class="cx"> 
</span><ins>+    FormDataElement isolatedCopy() const;
+
</ins><span class="cx">     template&lt;typename Encoder&gt;
</span><span class="cx">     void encode(Encoder&amp;) const;
</span><span class="cx">     template&lt;typename Decoder&gt;
</span><span class="lines">@@ -205,7 +207,7 @@
</span><span class="cx">     // FIXME: Both these functions perform a deep copy of m_elements, but differ in handling of other data members.
</span><span class="cx">     // How much of that is intentional? We need better names that explain the difference.
</span><span class="cx">     Ref&lt;FormData&gt; copy() const;
</span><del>-    Ref&lt;FormData&gt; deepCopy() const;
</del><ins>+    Ref&lt;FormData&gt; isolatedCopy() const;
</ins><span class="cx"> 
</span><span class="cx">     template&lt;typename Encoder&gt;
</span><span class="cx">     void encode(Encoder&amp;) const;
</span><span class="lines">@@ -263,10 +265,10 @@
</span><span class="cx"> 
</span><span class="cx">     Vector&lt;FormDataElement&gt; m_elements;
</span><span class="cx"> 
</span><del>-    int64_t m_identifier;
-    bool m_alwaysStream;
</del><ins>+    int64_t m_identifier { 0 };
+    bool m_alwaysStream { false };
</ins><span class="cx">     Vector&lt;char&gt; m_boundary;
</span><del>-    bool m_containsPasswordData;
</del><ins>+    bool m_containsPasswordData { false };
</ins><span class="cx"> };
</span><span class="cx"> 
</span><span class="cx"> inline bool operator==(const FormData&amp; a, const FormData&amp; b)
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworkHTTPHeaderMapcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/HTTPHeaderMap.cpp (201622 => 201623)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/HTTPHeaderMap.cpp        2016-06-02 22:18:27 UTC (rev 201622)
+++ trunk/Source/WebCore/platform/network/HTTPHeaderMap.cpp        2016-06-02 22:43:25 UTC (rev 201623)
</span><span class="lines">@@ -44,33 +44,19 @@
</span><span class="cx"> {
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-std::unique_ptr&lt;CrossThreadHTTPHeaderMapData&gt; HTTPHeaderMap::copyData() const
</del><ins>+HTTPHeaderMap HTTPHeaderMap::isolatedCopy() const
</ins><span class="cx"> {
</span><del>-    auto data = std::make_unique&lt;CrossThreadHTTPHeaderMapData&gt;();
</del><ins>+    HTTPHeaderMap map;
</ins><span class="cx"> 
</span><del>-    data-&gt;commonHeaders.reserveInitialCapacity(m_commonHeaders.size());
-    for (const auto&amp; header : m_commonHeaders)
-        data-&gt;commonHeaders.uncheckedAppend(std::make_pair(header.key, header.value.isolatedCopy()));
</del><ins>+    for (auto&amp; header : m_commonHeaders)
+        map.m_commonHeaders.set(header.key, header.value.isolatedCopy());
</ins><span class="cx"> 
</span><del>-    data-&gt;uncommonHeaders.reserveInitialCapacity(m_uncommonHeaders.size());
-    for (const auto&amp; header : m_uncommonHeaders)
-        data-&gt;uncommonHeaders.uncheckedAppend(std::make_pair(header.key.isolatedCopy(), header.value.isolatedCopy()));
</del><ins>+    for (auto&amp; header : m_uncommonHeaders)
+        map.m_uncommonHeaders.set(header.key.isolatedCopy(), header.value.isolatedCopy());
</ins><span class="cx"> 
</span><del>-    return data;
</del><ins>+    return map;
</ins><span class="cx"> }
</span><span class="cx"> 
</span><del>-void HTTPHeaderMap::adopt(std::unique_ptr&lt;CrossThreadHTTPHeaderMapData&gt; data)
-{
-    m_commonHeaders.clear();
-    m_uncommonHeaders.clear();
-
-    for (auto&amp; header : data-&gt;commonHeaders)
-        m_commonHeaders.add(header.first, WTFMove(header.second));
-
-    for (auto&amp; header : data-&gt;uncommonHeaders)
-        m_uncommonHeaders.add(WTFMove(header.first), WTFMove(header.second));
-}
-
</del><span class="cx"> String HTTPHeaderMap::get(const String&amp; name) const
</span><span class="cx"> {
</span><span class="cx">     HTTPHeaderName headerName;
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworkHTTPHeaderMaph"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/HTTPHeaderMap.h (201622 => 201623)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/HTTPHeaderMap.h        2016-06-02 22:18:27 UTC (rev 201622)
+++ trunk/Source/WebCore/platform/network/HTTPHeaderMap.h        2016-06-02 22:43:25 UTC (rev 201623)
</span><span class="lines">@@ -24,8 +24,7 @@
</span><span class="cx">  * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 
</span><span class="cx">  */
</span><span class="cx"> 
</span><del>-#ifndef HTTPHeaderMap_h
-#define HTTPHeaderMap_h
</del><ins>+#pragma once
</ins><span class="cx"> 
</span><span class="cx"> #include &quot;HTTPHeaderNames.h&quot;
</span><span class="cx"> #include &lt;utility&gt;
</span><span class="lines">@@ -38,11 +37,6 @@
</span><span class="cx"> 
</span><span class="cx"> namespace WebCore {
</span><span class="cx"> 
</span><del>-struct CrossThreadHTTPHeaderMapData {
-    Vector&lt;std::pair&lt;HTTPHeaderName, String&gt;&gt; commonHeaders;
-    Vector&lt;std::pair&lt;String, String&gt;&gt; uncommonHeaders;
-};
-
</del><span class="cx"> // FIXME: Not every header fits into a map. Notably, multiple Set-Cookie header fields are needed to set multiple cookies.
</span><span class="cx"> 
</span><span class="cx"> class HTTPHeaderMap {
</span><span class="lines">@@ -124,8 +118,7 @@
</span><span class="cx">     WEBCORE_EXPORT ~HTTPHeaderMap();
</span><span class="cx"> 
</span><span class="cx">     // Gets a copy of the data suitable for passing to another thread.
</span><del>-    std::unique_ptr&lt;CrossThreadHTTPHeaderMapData&gt; copyData() const;
-    void adopt(std::unique_ptr&lt;CrossThreadHTTPHeaderMapData&gt;);
</del><ins>+    HTTPHeaderMap isolatedCopy() const;
</ins><span class="cx"> 
</span><span class="cx">     bool isEmpty() const { return m_commonHeaders.isEmpty() &amp;&amp; m_uncommonHeaders.isEmpty(); }
</span><span class="cx">     int size() const { return m_commonHeaders.size() + m_uncommonHeaders.size(); }
</span><span class="lines">@@ -215,5 +208,3 @@
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> } // namespace WebCore
</span><del>-
-#endif // HTTPHeaderMap_h
</del></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworkResourceErrorBasecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/ResourceErrorBase.cpp (201622 => 201623)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/ResourceErrorBase.cpp        2016-06-02 22:18:27 UTC (rev 201622)
+++ trunk/Source/WebCore/platform/network/ResourceErrorBase.cpp        2016-06-02 22:43:25 UTC (rev 201623)
</span><span class="lines">@@ -31,6 +31,11 @@
</span><span class="cx"> 
</span><span class="cx"> const char* const errorDomainWebKitInternal = &quot;WebKitInternal&quot;;
</span><span class="cx"> 
</span><ins>+inline const ResourceError&amp; ResourceErrorBase::asResourceError() const
+{
+    return *static_cast&lt;const ResourceError*&gt;(this);
+}
+
</ins><span class="cx"> ResourceError ResourceErrorBase::isolatedCopy() const
</span><span class="cx"> {
</span><span class="cx">     lazyInit();
</span><span class="lines">@@ -43,7 +48,9 @@
</span><span class="cx">     errorCopy.m_isNull = m_isNull;
</span><span class="cx">     errorCopy.m_isCancellation = m_isCancellation;
</span><span class="cx">     errorCopy.m_isTimeout = m_isTimeout;
</span><del>-    platformCopy(errorCopy);
</del><ins>+
+    errorCopy.doPlatformIsolatedCopy(asResourceError());
+
</ins><span class="cx">     return errorCopy;
</span><span class="cx"> }
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworkResourceErrorBaseh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/ResourceErrorBase.h (201622 => 201623)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/ResourceErrorBase.h        2016-06-02 22:18:27 UTC (rev 201622)
+++ trunk/Source/WebCore/platform/network/ResourceErrorBase.h        2016-06-02 22:43:25 UTC (rev 201623)
</span><span class="lines">@@ -78,9 +78,6 @@
</span><span class="cx">     // The ResourceError subclass may &quot;shadow&quot; this method to lazily initialize platform specific fields
</span><span class="cx">     void platformLazyInit() {}
</span><span class="cx"> 
</span><del>-    // The ResourceError subclass may &quot;shadow&quot; this method to copy platform specific fields
-    void platformCopy(ResourceError&amp;) const {}
-
</del><span class="cx">     // The ResourceError subclass may &quot;shadow&quot; this method to compare platform specific fields
</span><span class="cx">     static bool platformCompare(const ResourceError&amp;, const ResourceError&amp;) { return true; }
</span><span class="cx"> 
</span><span class="lines">@@ -91,6 +88,9 @@
</span><span class="cx">     bool m_isNull : 1;
</span><span class="cx">     bool m_isCancellation : 1;
</span><span class="cx">     bool m_isTimeout : 1;
</span><ins>+
+private:
+    const ResourceError&amp; asResourceError() const;
</ins><span class="cx"> };
</span><span class="cx"> 
</span><span class="cx"> inline bool operator==(const ResourceError&amp; a, const ResourceError&amp; b) { return ResourceErrorBase::compare(a, b); }
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworkResourceLoadTimingh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/ResourceLoadTiming.h (201622 => 201623)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/ResourceLoadTiming.h        2016-06-02 22:18:27 UTC (rev 201622)
+++ trunk/Source/WebCore/platform/network/ResourceLoadTiming.h        2016-06-02 22:43:25 UTC (rev 201623)
</span><span class="lines">@@ -68,6 +68,12 @@
</span><span class="cx">         secureConnectionStart = other.secureConnectionStart;
</span><span class="cx">         return *this;
</span><span class="cx">     }
</span><ins>+
+    ResourceLoadTiming isolatedCopy() const
+    {
+        // There are currently no members that need isolated copies, so we can use the copy constructor.
+        return *this;
+    }
</ins><span class="cx">     
</span><span class="cx">     bool operator==(const ResourceLoadTiming&amp; other) const
</span><span class="cx">     {
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworkResourceRequestBasecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/ResourceRequestBase.cpp (201622 => 201623)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/ResourceRequestBase.cpp        2016-06-02 22:18:27 UTC (rev 201622)
+++ trunk/Source/WebCore/platform/network/ResourceRequestBase.cpp        2016-06-02 22:43:25 UTC (rev 201623)
</span><span class="lines">@@ -52,67 +52,43 @@
</span><span class="cx"> ResourceRequest ResourceRequestBase::isolatedCopy() const
</span><span class="cx"> {
</span><span class="cx">     ResourceRequest request;
</span><del>-    request.setAsIsolatedCopy(*this);
</del><ins>+    request.setAsIsolatedCopy(asResourceRequest());
</ins><span class="cx">     return request;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-void ResourceRequestBase::setAsIsolatedCopy(const ResourceRequestBase&amp; other)
</del><ins>+void ResourceRequestBase::setAsIsolatedCopy(const ResourceRequest&amp; other)
</ins><span class="cx"> {
</span><del>-    auto data = other.copyData();
</del><ins>+    setURL(other.url().isolatedCopy());
+    setCachePolicy(other.cachePolicy());
+    setTimeoutInterval(other.timeoutInterval());
+    setFirstPartyForCookies(other.firstPartyForCookies().isolatedCopy());
+    setHTTPMethod(other.httpMethod().isolatedCopy());
+    setPriority(other.priority());
+    setRequester(other.requester());
</ins><span class="cx"> 
</span><del>-    setURL(data-&gt;url);
-    setCachePolicy(data-&gt;cachePolicy);
-    setTimeoutInterval(data-&gt;timeoutInterval);
-    setFirstPartyForCookies(data-&gt;firstPartyForCookies);
-    setHTTPMethod(data-&gt;httpMethod);
-    setPriority(data-&gt;priority);
-    setRequester(data-&gt;requester);
-
</del><span class="cx">     updateResourceRequest();
</span><del>-    m_httpHeaderFields.adopt(WTFMove(data-&gt;httpHeaders));
</del><ins>+    m_httpHeaderFields = other.httpHeaderFields().isolatedCopy();
</ins><span class="cx"> 
</span><del>-    size_t encodingCount = data-&gt;responseContentDispositionEncodingFallbackArray.size();
</del><ins>+    size_t encodingCount = other.m_responseContentDispositionEncodingFallbackArray.size();
</ins><span class="cx">     if (encodingCount &gt; 0) {
</span><del>-        String encoding1 = data-&gt;responseContentDispositionEncodingFallbackArray[0];
</del><ins>+        String encoding1 = other.m_responseContentDispositionEncodingFallbackArray[0].isolatedCopy();
</ins><span class="cx">         String encoding2;
</span><span class="cx">         String encoding3;
</span><span class="cx">         if (encodingCount &gt; 1) {
</span><del>-            encoding2 = data-&gt;responseContentDispositionEncodingFallbackArray[1];
</del><ins>+            encoding2 = other.m_responseContentDispositionEncodingFallbackArray[1].isolatedCopy();
</ins><span class="cx">             if (encodingCount &gt; 2)
</span><del>-                encoding3 = data-&gt;responseContentDispositionEncodingFallbackArray[2];
</del><ins>+                encoding3 = other.m_responseContentDispositionEncodingFallbackArray[2].isolatedCopy();
</ins><span class="cx">         }
</span><span class="cx">         ASSERT(encodingCount &lt;= 3);
</span><span class="cx">         setResponseContentDispositionEncodingFallbackArray(encoding1, encoding2, encoding3);
</span><span class="cx">     }
</span><del>-    setHTTPBody(data-&gt;httpBody.copyRef());
-    setAllowCookies(data-&gt;allowCookies);
</del><ins>+    if (other.m_httpBody)
+        setHTTPBody(other.m_httpBody-&gt;isolatedCopy());
+    setAllowCookies(other.m_allowCookies);
</ins><span class="cx"> 
</span><del>-    const_cast&lt;ResourceRequest&amp;&gt;(asResourceRequest()).doPlatformAdopt(WTFMove(data));
</del><ins>+    const_cast&lt;ResourceRequest&amp;&gt;(asResourceRequest()).doPlatformSetAsIsolatedCopy(other);
</ins><span class="cx"> }
</span><span class="cx"> 
</span><del>-std::unique_ptr&lt;CrossThreadResourceRequestData&gt; ResourceRequestBase::copyData() const
-{
-    auto data = std::make_unique&lt;CrossThreadResourceRequestData&gt;();
-    data-&gt;url = url().isolatedCopy();
-    data-&gt;cachePolicy = m_cachePolicy;
-    data-&gt;timeoutInterval = timeoutInterval();
-    data-&gt;firstPartyForCookies = firstPartyForCookies().isolatedCopy();
-    data-&gt;httpMethod = httpMethod().isolatedCopy();
-    data-&gt;httpHeaders = httpHeaderFields().copyData();
-    data-&gt;priority = m_priority;
-    data-&gt;requester = m_requester;
-
-    data-&gt;responseContentDispositionEncodingFallbackArray.reserveInitialCapacity(m_responseContentDispositionEncodingFallbackArray.size());
-    size_t encodingArraySize = m_responseContentDispositionEncodingFallbackArray.size();
-    for (size_t index = 0; index &lt; encodingArraySize; ++index) {
-        data-&gt;responseContentDispositionEncodingFallbackArray.append(m_responseContentDispositionEncodingFallbackArray[index].isolatedCopy());
-    }
-    if (m_httpBody)
-        data-&gt;httpBody = m_httpBody-&gt;deepCopy();
-    data-&gt;allowCookies = m_allowCookies;
-    return asResourceRequest().doPlatformCopyData(WTFMove(data));
-}
-
</del><span class="cx"> bool ResourceRequestBase::isEmpty() const
</span><span class="cx"> {
</span><span class="cx">     updateResourceRequest(); 
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworkResourceRequestBaseh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/ResourceRequestBase.h (201622 => 201623)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/ResourceRequestBase.h        2016-06-02 22:18:27 UTC (rev 201622)
+++ trunk/Source/WebCore/platform/network/ResourceRequestBase.h        2016-06-02 22:43:25 UTC (rev 201623)
</span><span class="lines">@@ -48,14 +48,13 @@
</span><span class="cx"> };
</span><span class="cx"> 
</span><span class="cx"> class ResourceRequest;
</span><del>-struct CrossThreadResourceRequestData;
</del><span class="cx"> 
</span><span class="cx"> // Do not use this type directly.  Use ResourceRequest instead.
</span><span class="cx"> class ResourceRequestBase {
</span><span class="cx">     WTF_MAKE_FAST_ALLOCATED;
</span><span class="cx"> public:
</span><span class="cx">     ResourceRequest isolatedCopy() const;
</span><del>-    WEBCORE_EXPORT void setAsIsolatedCopy(const ResourceRequestBase&amp;);
</del><ins>+    WEBCORE_EXPORT void setAsIsolatedCopy(const ResourceRequest&amp;);
</ins><span class="cx"> 
</span><span class="cx">     WEBCORE_EXPORT bool isNull() const;
</span><span class="cx">     WEBCORE_EXPORT bool isEmpty() const;
</span><span class="lines">@@ -220,9 +219,6 @@
</span><span class="cx"> private:
</span><span class="cx">     const ResourceRequest&amp; asResourceRequest() const;
</span><span class="cx"> 
</span><del>-    // Gets a copy of the data suitable for passing to another thread.
-    std::unique_ptr&lt;CrossThreadResourceRequestData&gt; copyData() const;
-
</del><span class="cx">     WEBCORE_EXPORT static double s_defaultTimeoutInterval;
</span><span class="cx"> #if PLATFORM(IOS)
</span><span class="cx">     static bool s_defaultAllowCookies;
</span><span class="lines">@@ -234,20 +230,6 @@
</span><span class="cx"> inline bool operator==(const ResourceRequest&amp; a, const ResourceRequest&amp; b) { return ResourceRequestBase::compare(a, b); }
</span><span class="cx"> inline bool operator!=(ResourceRequest&amp; a, const ResourceRequest&amp; b) { return !(a == b); }
</span><span class="cx"> 
</span><del>-struct CrossThreadResourceRequestDataBase {
-    URL url;
-    ResourceRequestCachePolicy cachePolicy;
-    double timeoutInterval;
-    URL firstPartyForCookies;
-    String httpMethod;
-    std::unique_ptr&lt;CrossThreadHTTPHeaderMapData&gt; httpHeaders;
-    Vector&lt;String&gt; responseContentDispositionEncodingFallbackArray;
-    RefPtr&lt;FormData&gt; httpBody;
-    bool allowCookies;
-    ResourceLoadPriority priority;
-    ResourceRequestBase::Requester requester;
-};
-
</del><span class="cx"> WEBCORE_EXPORT unsigned initializeMaximumHTTPConnectionCountPerHost();
</span><span class="cx"> #if PLATFORM(IOS)
</span><span class="cx"> WEBCORE_EXPORT void initializeHTTPConnectionSettingsOnStartup();
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworkResourceResponseBasecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/ResourceResponseBase.cpp (201622 => 201623)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/ResourceResponseBase.cpp        2016-06-02 22:18:27 UTC (rev 201622)
+++ trunk/Source/WebCore/platform/network/ResourceResponseBase.cpp        2016-06-02 22:43:25 UTC (rev 201623)
</span><span class="lines">@@ -66,42 +66,24 @@
</span><span class="cx"> ResourceResponse ResourceResponseBase::isolatedCopy() const
</span><span class="cx"> {
</span><span class="cx">     ResourceResponse response;
</span><del>-    auto data = copyData();
</del><span class="cx"> 
</span><del>-    response.setURL(data-&gt;m_url);
-    response.setMimeType(data-&gt;m_mimeType);
-    response.setExpectedContentLength(data-&gt;m_expectedContentLength);
-    response.setTextEncodingName(data-&gt;m_textEncodingName);
</del><ins>+    response.setURL(url().isolatedCopy());
+    response.setMimeType(mimeType().isolatedCopy());
+    response.setExpectedContentLength(expectedContentLength());
+    response.setTextEncodingName(textEncodingName().isolatedCopy());
</ins><span class="cx"> 
</span><del>-    response.setHTTPStatusCode(data-&gt;m_httpStatusCode);
-    response.setHTTPStatusText(data-&gt;m_httpStatusText);
-    response.setHTTPVersion(data-&gt;m_httpVersion);
</del><ins>+    response.setHTTPStatusCode(httpStatusCode());
+    response.setHTTPStatusText(httpStatusText().isolatedCopy());
+    response.setHTTPVersion(httpVersion().isolatedCopy());
</ins><span class="cx"> 
</span><span class="cx">     response.lazyInit(AllFields);
</span><del>-    response.m_httpHeaderFields.adopt(WTFMove(data-&gt;m_httpHeaders));
-    response.m_resourceLoadTiming = data-&gt;m_resourceLoadTiming;
-    response.m_type = data-&gt;m_type;
-    response.doPlatformAdopt(WTFMove(data));
</del><ins>+    response.m_httpHeaderFields = httpHeaderFields().isolatedCopy();
+    response.m_resourceLoadTiming = m_resourceLoadTiming.isolatedCopy();
+    response.m_type = m_type;
</ins><span class="cx"> 
</span><span class="cx">     return response;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-std::unique_ptr&lt;CrossThreadResourceResponseData&gt; ResourceResponseBase::copyData() const
-{
-    auto data = std::make_unique&lt;CrossThreadResourceResponseData&gt;();
-    data-&gt;m_url = url().isolatedCopy();
-    data-&gt;m_mimeType = mimeType().isolatedCopy();
-    data-&gt;m_expectedContentLength = expectedContentLength();
-    data-&gt;m_textEncodingName = textEncodingName().isolatedCopy();
-    data-&gt;m_httpStatusCode = httpStatusCode();
-    data-&gt;m_httpStatusText = httpStatusText().isolatedCopy();
-    data-&gt;m_httpVersion = httpVersion().isolatedCopy();
-    data-&gt;m_httpHeaders = httpHeaderFields().copyData();
-    data-&gt;m_resourceLoadTiming = m_resourceLoadTiming;
-    data-&gt;m_type = m_type;
-    return asResourceResponse().doPlatformCopyData(WTFMove(data));
-}
-
</del><span class="cx"> // FIXME: Name does not make it clear this is true for HTTPS!
</span><span class="cx"> bool ResourceResponseBase::isHTTP() const
</span><span class="cx"> {
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworkResourceResponseBaseh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/ResourceResponseBase.h (201622 => 201623)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/ResourceResponseBase.h        2016-06-02 22:18:27 UTC (rev 201622)
+++ trunk/Source/WebCore/platform/network/ResourceResponseBase.h        2016-06-02 22:43:25 UTC (rev 201623)
</span><span class="lines">@@ -40,7 +40,6 @@
</span><span class="cx"> namespace WebCore {
</span><span class="cx"> 
</span><span class="cx"> class ResourceResponse;
</span><del>-struct CrossThreadResourceResponseData;
</del><span class="cx"> 
</span><span class="cx"> // Do not use this class directly, use the class ResponseResponse instead
</span><span class="cx"> class ResourceResponseBase {
</span><span class="lines">@@ -159,9 +158,6 @@
</span><span class="cx">     void parseCacheControlDirectives() const;
</span><span class="cx">     void updateHeaderParsedState(HTTPHeaderName);
</span><span class="cx"> 
</span><del>-    // Gets a copy of the data suitable for passing to another thread.
-    std::unique_ptr&lt;CrossThreadResourceResponseData&gt; copyData() const;
-
</del><span class="cx"> protected:
</span><span class="cx">     bool m_isNull;
</span><span class="cx">     URL m_url;
</span><span class="lines">@@ -274,21 +270,4 @@
</span><span class="cx">     return true;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-struct CrossThreadResourceResponseDataBase {
-    WTF_MAKE_NONCOPYABLE(CrossThreadResourceResponseDataBase); WTF_MAKE_FAST_ALLOCATED;
-public:
-    CrossThreadResourceResponseDataBase() { }
-    URL m_url;
-    String m_mimeType;
-    long long m_expectedContentLength;
-    String m_textEncodingName;
-    int m_httpStatusCode;
-    String m_httpStatusText;
-    String m_httpVersion;
-    std::unique_ptr&lt;CrossThreadHTTPHeaderMapData&gt; m_httpHeaders;
-    ResourceLoadTiming m_resourceLoadTiming;
-    ResourceResponseBase::Type m_type;
-    bool m_isRedirected;
-};
-
</del><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworkcfResourceErrorh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/cf/ResourceError.h (201622 => 201623)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/cf/ResourceError.h        2016-06-02 22:18:27 UTC (rev 201622)
+++ trunk/Source/WebCore/platform/network/cf/ResourceError.h        2016-06-02 22:43:25 UTC (rev 201623)
</span><span class="lines">@@ -83,7 +83,9 @@
</span><span class="cx">     friend class ResourceErrorBase;
</span><span class="cx"> 
</span><span class="cx">     void platformLazyInit();
</span><del>-    void platformCopy(ResourceError&amp;) const;
</del><ins>+
+    void doPlatformIsolatedCopy(const ResourceError&amp;);
+
</ins><span class="cx">     bool m_dataIsUpToDate;
</span><span class="cx"> #if USE(CFNETWORK)
</span><span class="cx">     mutable RetainPtr&lt;CFErrorRef&gt; m_platformError;
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworkcfResourceErrorCFcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/cf/ResourceErrorCF.cpp (201622 => 201623)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/cf/ResourceErrorCF.cpp        2016-06-02 22:18:27 UTC (rev 201622)
+++ trunk/Source/WebCore/platform/network/cf/ResourceErrorCF.cpp        2016-06-02 22:43:25 UTC (rev 201623)
</span><span class="lines">@@ -119,12 +119,13 @@
</span><span class="cx">     m_dataIsUpToDate = true;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-void ResourceError::platformCopy(ResourceError&amp; errorCopy) const
</del><ins>+
+void ResourceError::doPlatformIsolatedCopy(const ResourceError&amp; other)
</ins><span class="cx"> {
</span><span class="cx"> #if PLATFORM(WIN)
</span><del>-    errorCopy.m_certificate = m_certificate;
</del><ins>+    m_certificate = other.m_certificate;
</ins><span class="cx"> #else
</span><del>-    UNUSED_PARAM(errorCopy);
</del><ins>+    UNUSED_PARAM(other);
</ins><span class="cx"> #endif
</span><span class="cx"> }
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworkcfResourceRequesth"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/cf/ResourceRequest.h (201622 => 201623)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/cf/ResourceRequest.h        2016-06-02 22:18:27 UTC (rev 201622)
+++ trunk/Source/WebCore/platform/network/cf/ResourceRequest.h        2016-06-02 22:43:25 UTC (rev 201623)
</span><span class="lines">@@ -126,8 +126,7 @@
</span><span class="cx">     void doUpdatePlatformHTTPBody();
</span><span class="cx">     void doUpdateResourceHTTPBody();
</span><span class="cx"> 
</span><del>-    std::unique_ptr&lt;CrossThreadResourceRequestData&gt; doPlatformCopyData(std::unique_ptr&lt;CrossThreadResourceRequestData&gt;) const;
-    void doPlatformAdopt(std::unique_ptr&lt;CrossThreadResourceRequestData&gt;);
</del><ins>+    void doPlatformSetAsIsolatedCopy(const ResourceRequest&amp;);
</ins><span class="cx"> 
</span><span class="cx"> #if USE(CFNETWORK)
</span><span class="cx">     RetainPtr&lt;CFURLRequestRef&gt; m_cfRequest;
</span><span class="lines">@@ -142,12 +141,6 @@
</span><span class="cx">     static bool s_httpPipeliningEnabled;
</span><span class="cx"> };
</span><span class="cx"> 
</span><del>-struct CrossThreadResourceRequestData : public CrossThreadResourceRequestDataBase {
-#if ENABLE(CACHE_PARTITIONING)
-    String m_cachePartition;
-#endif
-};
-
</del><span class="cx"> inline bool ResourceRequest::resourcePrioritiesEnabled()
</span><span class="cx"> {
</span><span class="cx"> #if PLATFORM(MAC)
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworkcfResourceRequestCFNetcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/cf/ResourceRequestCFNet.cpp (201622 => 201623)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/cf/ResourceRequestCFNet.cpp        2016-06-02 22:18:27 UTC (rev 201622)
+++ trunk/Source/WebCore/platform/network/cf/ResourceRequestCFNet.cpp        2016-06-02 22:43:25 UTC (rev 201623)
</span><span class="lines">@@ -366,23 +366,16 @@
</span><span class="cx"> }
</span><span class="cx"> #endif
</span><span class="cx"> 
</span><del>-std::unique_ptr&lt;CrossThreadResourceRequestData&gt; ResourceRequest::doPlatformCopyData(std::unique_ptr&lt;CrossThreadResourceRequestData&gt; data) const
</del><ins>+void ResourceRequest::doPlatformSetAsIsolatedCopy(const ResourceRequest&amp; other)
</ins><span class="cx"> {
</span><span class="cx"> #if ENABLE(CACHE_PARTITIONING)
</span><del>-    data-&gt;m_cachePartition = m_cachePartition;
-#endif
-    return data;
-}
-
-void ResourceRequest::doPlatformAdopt(std::unique_ptr&lt;CrossThreadResourceRequestData&gt; data)
-{
-#if ENABLE(CACHE_PARTITIONING)
-    m_cachePartition = data-&gt;m_cachePartition;
</del><ins>+    m_cachePartition = other.m_cachePartition.isolatedCopy();
</ins><span class="cx"> #else
</span><del>-    UNUSED_PARAM(data);
</del><ins>+    UNUSED_PARAM(other);
</ins><span class="cx"> #endif
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+
</ins><span class="cx"> // FIXME: It is confusing that this function both sets connection count and determines maximum request count at network layer. This can and should be done separately.
</span><span class="cx"> unsigned initializeMaximumHTTPConnectionCountPerHost()
</span><span class="cx"> {
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworkcfResourceResponseh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/cf/ResourceResponse.h (201622 => 201623)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/cf/ResourceResponse.h        2016-06-02 22:18:27 UTC (rev 201622)
+++ trunk/Source/WebCore/platform/network/cf/ResourceResponse.h        2016-06-02 22:43:25 UTC (rev 201623)
</span><span class="lines">@@ -100,8 +100,8 @@
</span><span class="cx">     String platformSuggestedFilename() const;
</span><span class="cx">     CertificateInfo platformCertificateInfo() const;
</span><span class="cx"> 
</span><del>-    std::unique_ptr&lt;CrossThreadResourceResponseData&gt; doPlatformCopyData(std::unique_ptr&lt;CrossThreadResourceResponseData&gt; data) const { return data; }
-    void doPlatformAdopt(std::unique_ptr&lt;CrossThreadResourceResponseData&gt;) { }
</del><ins>+    void doPlatformSetAsIsolatedCopy(const ResourceResponse&amp;) const;
+
</ins><span class="cx"> #if PLATFORM(COCOA)
</span><span class="cx">     void initNSURLResponse() const;
</span><span class="cx"> #endif
</span><span class="lines">@@ -119,7 +119,4 @@
</span><span class="cx"> #endif
</span><span class="cx"> };
</span><span class="cx"> 
</span><del>-struct CrossThreadResourceResponseData : public CrossThreadResourceResponseDataBase {
-};
-
</del><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworkcurlResourceErrorh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/curl/ResourceError.h (201622 => 201623)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/curl/ResourceError.h        2016-06-02 22:18:27 UTC (rev 201622)
+++ trunk/Source/WebCore/platform/network/curl/ResourceError.h        2016-06-02 22:43:25 UTC (rev 201623)
</span><span class="lines">@@ -54,6 +54,9 @@
</span><span class="cx">     bool hasSSLConnectError() const { return errorCode() == CURLE_SSL_CONNECT_ERROR; }
</span><span class="cx"> 
</span><span class="cx"> private:
</span><ins>+    friend class ResourceErrorBase;
+    void doPlatformIsolatedCopy(const ResourceError&amp;) { }
+
</ins><span class="cx">     unsigned m_sslErrors;
</span><span class="cx"> };
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworkcurlResourceRequesth"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/curl/ResourceRequest.h (201622 => 201623)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/curl/ResourceRequest.h        2016-06-02 22:18:27 UTC (rev 201622)
+++ trunk/Source/WebCore/platform/network/curl/ResourceRequest.h        2016-06-02 22:43:25 UTC (rev 201623)
</span><span class="lines">@@ -78,15 +78,11 @@
</span><span class="cx">         void doUpdatePlatformHTTPBody() { }
</span><span class="cx">         void doUpdateResourceHTTPBody() { }
</span><span class="cx"> 
</span><del>-        std::unique_ptr&lt;CrossThreadResourceRequestData&gt; doPlatformCopyData(std::unique_ptr&lt;CrossThreadResourceRequestData&gt; data) const { return data; }
-        void doPlatformAdopt(std::unique_ptr&lt;CrossThreadResourceRequestData&gt;) { }

</del><ins>+        void doPlatformSetAsIsolatedCopy(const ResourceRequest&amp;) { }
+
</ins><span class="cx">         static bool s_httpPipeliningEnabled;
</span><span class="cx">     };
</span><span class="cx"> 
</span><del>-    struct CrossThreadResourceRequestData : public CrossThreadResourceRequestDataBase {
-    };
-
</del><span class="cx"> } // namespace WebCore
</span><span class="cx"> 
</span><span class="cx"> #endif // ResourceRequest_h
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworkcurlResourceResponseh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/curl/ResourceResponse.h (201622 => 201623)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/curl/ResourceResponse.h        2016-06-02 22:18:27 UTC (rev 201622)
+++ trunk/Source/WebCore/platform/network/curl/ResourceResponse.h        2016-06-02 22:43:25 UTC (rev 201623)
</span><span class="lines">@@ -59,8 +59,6 @@
</span><span class="cx"> private:
</span><span class="cx">     friend class ResourceResponseBase;
</span><span class="cx"> 
</span><del>-    std::unique_ptr&lt;CrossThreadResourceResponseData&gt; doPlatformCopyData(std::unique_ptr&lt;CrossThreadResourceResponseData&gt; data) const { return data; }
-    void doPlatformAdopt(std::unique_ptr&lt;CrossThreadResourceResponseData&gt;) { }
</del><span class="cx">     String platformSuggestedFilename() const
</span><span class="cx">     {
</span><span class="cx">         return filenameFromHTTPContentDisposition(httpHeaderField(HTTPHeaderName::ContentDisposition));
</span><span class="lines">@@ -69,9 +67,6 @@
</span><span class="cx">     bool m_responseFired;
</span><span class="cx"> };
</span><span class="cx"> 
</span><del>-struct CrossThreadResourceResponseData : public CrossThreadResourceResponseDataBase {
-};
-
</del><span class="cx"> } // namespace WebCore
</span><span class="cx"> 
</span><span class="cx"> #endif // ResourceResponse_h
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworkmacResourceErrorMacmm"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/mac/ResourceErrorMac.mm (201622 => 201623)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/mac/ResourceErrorMac.mm        2016-06-02 22:18:27 UTC (rev 201622)
+++ trunk/Source/WebCore/platform/network/mac/ResourceErrorMac.mm        2016-06-02 22:43:25 UTC (rev 201623)
</span><span class="lines">@@ -281,6 +281,10 @@
</span><span class="cx">     return a.nsError() == b.nsError();
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+void ResourceError::doPlatformIsolatedCopy(const ResourceError&amp;)
+{
+}
+
</ins><span class="cx"> NSError *ResourceError::nsError() const
</span><span class="cx"> {
</span><span class="cx">     if (m_isNull) {
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworksoupResourceErrorh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/soup/ResourceError.h (201622 => 201623)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/soup/ResourceError.h        2016-06-02 22:18:27 UTC (rev 201622)
+++ trunk/Source/WebCore/platform/network/soup/ResourceError.h        2016-06-02 22:43:25 UTC (rev 201623)
</span><span class="lines">@@ -67,7 +67,8 @@
</span><span class="cx">     static bool platformCompare(const ResourceError&amp; a, const ResourceError&amp; b);
</span><span class="cx"> 
</span><span class="cx"> private:
</span><del>-    void platformCopy(ResourceError&amp;) const;
</del><ins>+    friend class ResourceErrorBase;
+    void doPlatformIsolatedCopy(const ResourceError&amp;);
</ins><span class="cx"> 
</span><span class="cx">     unsigned m_tlsErrors;
</span><span class="cx">     GRefPtr&lt;GTlsCertificate&gt; m_certificate;
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworksoupResourceErrorSoupcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/soup/ResourceErrorSoup.cpp (201622 => 201623)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/soup/ResourceErrorSoup.cpp        2016-06-02 22:18:27 UTC (rev 201622)
+++ trunk/Source/WebCore/platform/network/soup/ResourceErrorSoup.cpp        2016-06-02 22:43:25 UTC (rev 201623)
</span><span class="lines">@@ -97,10 +97,10 @@
</span><span class="cx">     return error;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-void ResourceError::platformCopy(ResourceError&amp; errorCopy) const
</del><ins>+void ResourceError::doPlatformIsolatedCopy(const ResourceError&amp; other)
</ins><span class="cx"> {
</span><del>-    errorCopy.m_certificate = m_certificate;
-    errorCopy.m_tlsErrors = m_tlsErrors;
</del><ins>+    m_certificate = other.m_certificate;
+    m_tlsErrors = other.m_tlsErrors;
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> bool ResourceError::platformCompare(const ResourceError&amp; a, const ResourceError&amp; b)
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworksoupResourceRequesth"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/soup/ResourceRequest.h (201622 => 201623)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/soup/ResourceRequest.h        2016-06-02 22:18:27 UTC (rev 201622)
+++ trunk/Source/WebCore/platform/network/soup/ResourceRequest.h        2016-06-02 22:43:25 UTC (rev 201623)
</span><span class="lines">@@ -120,13 +120,9 @@
</span><span class="cx">         void doUpdatePlatformHTTPBody() { }
</span><span class="cx">         void doUpdateResourceHTTPBody() { }
</span><span class="cx"> 
</span><del>-        std::unique_ptr&lt;CrossThreadResourceRequestData&gt; doPlatformCopyData(std::unique_ptr&lt;CrossThreadResourceRequestData&gt; data) const { return data; }
-        void doPlatformAdopt(std::unique_ptr&lt;CrossThreadResourceRequestData&gt;) { }
</del><ins>+        void doPlatformSetAsIsolatedCopy(const ResourceRequest&amp;) { }
</ins><span class="cx">     };
</span><span class="cx"> 
</span><del>-    struct CrossThreadResourceRequestData : public CrossThreadResourceRequestDataBase {
-    };
-
</del><span class="cx"> #if SOUP_CHECK_VERSION(2, 43, 1)
</span><span class="cx"> inline SoupMessagePriority toSoupMessagePriority(ResourceLoadPriority priority)
</span><span class="cx"> {
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworksoupResourceResponseh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/soup/ResourceResponse.h (201622 => 201623)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/soup/ResourceResponse.h        2016-06-02 22:18:27 UTC (rev 201622)
+++ trunk/Source/WebCore/platform/network/soup/ResourceResponse.h        2016-06-02 22:43:25 UTC (rev 201623)
</span><span class="lines">@@ -90,9 +90,6 @@
</span><span class="cx">     void doUpdateResourceResponse() { }
</span><span class="cx">     String platformSuggestedFilename() const;
</span><span class="cx">     CertificateInfo platformCertificateInfo() const;
</span><del>-
-    std::unique_ptr&lt;CrossThreadResourceResponseData&gt; doPlatformCopyData(std::unique_ptr&lt;CrossThreadResourceResponseData&gt; data) const { return data; }
-    void doPlatformAdopt(std::unique_ptr&lt;CrossThreadResourceResponseData&gt;) { }
</del><span class="cx"> };
</span><span class="cx"> 
</span><span class="cx"> template&lt;class Encoder&gt;
</span><span class="lines">@@ -112,9 +109,6 @@
</span><span class="cx">     return true;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-struct CrossThreadResourceResponseData : public CrossThreadResourceResponseDataBase {
-};
-
</del><span class="cx"> } // namespace WebCore
</span><span class="cx"> 
</span><span class="cx"> #endif // ResourceResponse_h
</span></span></pre>
</div>
</div>

</body>
</html>