<!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>[198869] trunk/Source</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/198869">198869</a></dd>
<dt>Author</dt> <dd>beidson@apple.com</dd>
<dt>Date</dt> <dd>2016-03-30 18:21:04 -0700 (Wed, 30 Mar 2016)</dd>
</dl>
<h3>Log Message</h3>
<pre>Make BlobData use ThreadSafeSharedBuffer instead of RawData.
https://bugs.webkit.org/show_bug.cgi?id=156041
Reviewed by Alex Christensen.
Source/WebCore:
No new tests (No change in behavior).
* Modules/fetch/FetchBody.cpp:
(WebCore::FetchBody::consumeText):
(WebCore::FetchBody::extractFromText):
(WebCore::blobFromArrayBuffer):
* Modules/fetch/FetchBody.h:
* Modules/websockets/ThreadableWebSocketChannelClientWrapper.cpp:
(WebCore::ThreadableWebSocketChannelClientWrapper::didReceiveBinaryData):
* Modules/websockets/ThreadableWebSocketChannelClientWrapper.h:
* Modules/websockets/WebSocket.cpp:
(WebCore::WebSocket::didReceiveBinaryData):
* Modules/websockets/WebSocket.h:
* Modules/websockets/WebSocketChannel.cpp:
(WebCore::WebSocketChannel::processFrame):
* Modules/websockets/WebSocketChannel.h:
* Modules/websockets/WebSocketChannelClient.h:
(WebCore::WebSocketChannelClient::didReceiveBinaryData):
* Modules/websockets/WorkerThreadableWebSocketChannel.cpp:
(WebCore::WorkerThreadableWebSocketChannel::Peer::didReceiveBinaryData):
* Modules/websockets/WorkerThreadableWebSocketChannel.h:
* fileapi/Blob.cpp:
(WebCore::Blob::Blob):
* fileapi/Blob.h:
(WebCore::Blob::create):
* fileapi/WebKitBlobBuilder.h:
* platform/network/BlobData.cpp:
(WebCore::BlobData::BlobData):
(WebCore::BlobDataItem::length):
(WebCore::BlobData::appendData):
(WebCore::BlobData::setContentType): Deleted.
* platform/network/BlobData.h:
(WebCore::BlobDataItem::type):
(WebCore::BlobDataItem::data):
(WebCore::BlobDataItem::file):
(WebCore::BlobDataItem::BlobDataItem):
(WebCore::BlobData::create):
(WebCore::RawData::create): Deleted.
(WebCore::RawData::data): Deleted.
(WebCore::RawData::length): Deleted.
(WebCore::RawData::RawData): Deleted.
* platform/network/BlobPart.h:
(WebCore::BlobPart::BlobPart):
(WebCore::BlobPart::data):
(WebCore::BlobPart::moveData):
* platform/network/BlobRegistryImpl.cpp:
(WebCore::BlobRegistryImpl::appendStorageItems):
(WebCore::BlobRegistryImpl::registerFileBlobURL):
(WebCore::BlobRegistryImpl::registerBlobURL):
(WebCore::BlobRegistryImpl::registerBlobURLForSlice):
* platform/network/BlobResourceHandle.cpp:
(WebCore::BlobResourceHandle::getSizeForNext):
(WebCore::BlobResourceHandle::readSync):
(WebCore::BlobResourceHandle::readDataSync):
(WebCore::BlobResourceHandle::readFileSync):
(WebCore::BlobResourceHandle::readAsync):
(WebCore::BlobResourceHandle::readDataAsync):
(WebCore::BlobResourceHandle::readFileAsync):
* platform/network/BlobResourceHandle.h:
* platform/network/FormData.cpp:
(WebCore::appendBlobResolved):
* platform/network/soup/ResourceHandleSoup.cpp:
(WebCore::blobIsOutOfDate):
(WebCore::addEncodedBlobItemToSoupMessageBody):
* platform/text/LineEnding.cpp:
(WebCore::normalizeToCROrLF):
(WebCore::normalizeLineEndingsToNative):
(WebCore::normalizeLineEndingsToCR): Deleted.
(WebCore::normalizeLineEndingsToLF): Deleted.
* platform/text/LineEnding.h:
* xml/XMLHttpRequest.cpp:
(WebCore::XMLHttpRequest::responseBlob):
Source/WebKit2:
* NetworkProcess/FileAPI/NetworkBlobRegistry.cpp:
(WebKit::NetworkBlobRegistry::filesInBlob):
* Shared/WebCoreArgumentCoders.cpp:
(IPC::ArgumentCoder<BlobPart>::decode):</pre>
<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkSourceWebCoreChangeLog">trunk/Source/WebCore/ChangeLog</a></li>
<li><a href="#trunkSourceWebCoreModulesfetchFetchBodycpp">trunk/Source/WebCore/Modules/fetch/FetchBody.cpp</a></li>
<li><a href="#trunkSourceWebCoreModulesfetchFetchBodyh">trunk/Source/WebCore/Modules/fetch/FetchBody.h</a></li>
<li><a href="#trunkSourceWebCoreModuleswebsocketsThreadableWebSocketChannelClientWrappercpp">trunk/Source/WebCore/Modules/websockets/ThreadableWebSocketChannelClientWrapper.cpp</a></li>
<li><a href="#trunkSourceWebCoreModuleswebsocketsThreadableWebSocketChannelClientWrapperh">trunk/Source/WebCore/Modules/websockets/ThreadableWebSocketChannelClientWrapper.h</a></li>
<li><a href="#trunkSourceWebCoreModuleswebsocketsWebSocketcpp">trunk/Source/WebCore/Modules/websockets/WebSocket.cpp</a></li>
<li><a href="#trunkSourceWebCoreModuleswebsocketsWebSocketh">trunk/Source/WebCore/Modules/websockets/WebSocket.h</a></li>
<li><a href="#trunkSourceWebCoreModuleswebsocketsWebSocketChannelcpp">trunk/Source/WebCore/Modules/websockets/WebSocketChannel.cpp</a></li>
<li><a href="#trunkSourceWebCoreModuleswebsocketsWebSocketChannelh">trunk/Source/WebCore/Modules/websockets/WebSocketChannel.h</a></li>
<li><a href="#trunkSourceWebCoreModuleswebsocketsWebSocketChannelClienth">trunk/Source/WebCore/Modules/websockets/WebSocketChannelClient.h</a></li>
<li><a href="#trunkSourceWebCoreModuleswebsocketsWorkerThreadableWebSocketChannelcpp">trunk/Source/WebCore/Modules/websockets/WorkerThreadableWebSocketChannel.cpp</a></li>
<li><a href="#trunkSourceWebCoreModuleswebsocketsWorkerThreadableWebSocketChannelh">trunk/Source/WebCore/Modules/websockets/WorkerThreadableWebSocketChannel.h</a></li>
<li><a href="#trunkSourceWebCorefileapiBlobcpp">trunk/Source/WebCore/fileapi/Blob.cpp</a></li>
<li><a href="#trunkSourceWebCorefileapiBlobh">trunk/Source/WebCore/fileapi/Blob.h</a></li>
<li><a href="#trunkSourceWebCorefileapiWebKitBlobBuilderh">trunk/Source/WebCore/fileapi/WebKitBlobBuilder.h</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworkBlobDatacpp">trunk/Source/WebCore/platform/network/BlobData.cpp</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworkBlobDatah">trunk/Source/WebCore/platform/network/BlobData.h</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworkBlobParth">trunk/Source/WebCore/platform/network/BlobPart.h</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworkBlobRegistryImplcpp">trunk/Source/WebCore/platform/network/BlobRegistryImpl.cpp</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworkBlobResourceHandlecpp">trunk/Source/WebCore/platform/network/BlobResourceHandle.cpp</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworkBlobResourceHandleh">trunk/Source/WebCore/platform/network/BlobResourceHandle.h</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworkFormDatacpp">trunk/Source/WebCore/platform/network/FormData.cpp</a></li>
<li><a href="#trunkSourceWebCoreplatformnetworksoupResourceHandleSoupcpp">trunk/Source/WebCore/platform/network/soup/ResourceHandleSoup.cpp</a></li>
<li><a href="#trunkSourceWebCoreplatformtextLineEndingcpp">trunk/Source/WebCore/platform/text/LineEnding.cpp</a></li>
<li><a href="#trunkSourceWebCoreplatformtextLineEndingh">trunk/Source/WebCore/platform/text/LineEnding.h</a></li>
<li><a href="#trunkSourceWebCorexmlXMLHttpRequestcpp">trunk/Source/WebCore/xml/XMLHttpRequest.cpp</a></li>
<li><a href="#trunkSourceWebKit2ChangeLog">trunk/Source/WebKit2/ChangeLog</a></li>
<li><a href="#trunkSourceWebKit2NetworkProcessFileAPINetworkBlobRegistrycpp">trunk/Source/WebKit2/NetworkProcess/FileAPI/NetworkBlobRegistry.cpp</a></li>
<li><a href="#trunkSourceWebKit2SharedWebCoreArgumentCoderscpp">trunk/Source/WebKit2/Shared/WebCoreArgumentCoders.cpp</a></li>
</ul>
</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/ChangeLog (198868 => 198869)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/ChangeLog        2016-03-31 00:47:15 UTC (rev 198868)
+++ trunk/Source/WebCore/ChangeLog        2016-03-31 01:21:04 UTC (rev 198869)
</span><span class="lines">@@ -1,3 +1,83 @@
</span><ins>+2016-03-30 Brady Eidson <beidson@apple.com>
+
+ Make BlobData use ThreadSafeSharedBuffer instead of RawData.
+ https://bugs.webkit.org/show_bug.cgi?id=156041
+
+ Reviewed by Alex Christensen.
+
+ No new tests (No change in behavior).
+
+ * Modules/fetch/FetchBody.cpp:
+ (WebCore::FetchBody::consumeText):
+ (WebCore::FetchBody::extractFromText):
+ (WebCore::blobFromArrayBuffer):
+ * Modules/fetch/FetchBody.h:
+ * Modules/websockets/ThreadableWebSocketChannelClientWrapper.cpp:
+ (WebCore::ThreadableWebSocketChannelClientWrapper::didReceiveBinaryData):
+ * Modules/websockets/ThreadableWebSocketChannelClientWrapper.h:
+ * Modules/websockets/WebSocket.cpp:
+ (WebCore::WebSocket::didReceiveBinaryData):
+ * Modules/websockets/WebSocket.h:
+ * Modules/websockets/WebSocketChannel.cpp:
+ (WebCore::WebSocketChannel::processFrame):
+ * Modules/websockets/WebSocketChannel.h:
+ * Modules/websockets/WebSocketChannelClient.h:
+ (WebCore::WebSocketChannelClient::didReceiveBinaryData):
+ * Modules/websockets/WorkerThreadableWebSocketChannel.cpp:
+ (WebCore::WorkerThreadableWebSocketChannel::Peer::didReceiveBinaryData):
+ * Modules/websockets/WorkerThreadableWebSocketChannel.h:
+ * fileapi/Blob.cpp:
+ (WebCore::Blob::Blob):
+ * fileapi/Blob.h:
+ (WebCore::Blob::create):
+ * fileapi/WebKitBlobBuilder.h:
+ * platform/network/BlobData.cpp:
+ (WebCore::BlobData::BlobData):
+ (WebCore::BlobDataItem::length):
+ (WebCore::BlobData::appendData):
+ (WebCore::BlobData::setContentType): Deleted.
+ * platform/network/BlobData.h:
+ (WebCore::BlobDataItem::type):
+ (WebCore::BlobDataItem::data):
+ (WebCore::BlobDataItem::file):
+ (WebCore::BlobDataItem::BlobDataItem):
+ (WebCore::BlobData::create):
+ (WebCore::RawData::create): Deleted.
+ (WebCore::RawData::data): Deleted.
+ (WebCore::RawData::length): Deleted.
+ (WebCore::RawData::RawData): Deleted.
+ * platform/network/BlobPart.h:
+ (WebCore::BlobPart::BlobPart):
+ (WebCore::BlobPart::data):
+ (WebCore::BlobPart::moveData):
+ * platform/network/BlobRegistryImpl.cpp:
+ (WebCore::BlobRegistryImpl::appendStorageItems):
+ (WebCore::BlobRegistryImpl::registerFileBlobURL):
+ (WebCore::BlobRegistryImpl::registerBlobURL):
+ (WebCore::BlobRegistryImpl::registerBlobURLForSlice):
+ * platform/network/BlobResourceHandle.cpp:
+ (WebCore::BlobResourceHandle::getSizeForNext):
+ (WebCore::BlobResourceHandle::readSync):
+ (WebCore::BlobResourceHandle::readDataSync):
+ (WebCore::BlobResourceHandle::readFileSync):
+ (WebCore::BlobResourceHandle::readAsync):
+ (WebCore::BlobResourceHandle::readDataAsync):
+ (WebCore::BlobResourceHandle::readFileAsync):
+ * platform/network/BlobResourceHandle.h:
+ * platform/network/FormData.cpp:
+ (WebCore::appendBlobResolved):
+ * platform/network/soup/ResourceHandleSoup.cpp:
+ (WebCore::blobIsOutOfDate):
+ (WebCore::addEncodedBlobItemToSoupMessageBody):
+ * platform/text/LineEnding.cpp:
+ (WebCore::normalizeToCROrLF):
+ (WebCore::normalizeLineEndingsToNative):
+ (WebCore::normalizeLineEndingsToCR): Deleted.
+ (WebCore::normalizeLineEndingsToLF): Deleted.
+ * platform/text/LineEnding.h:
+ * xml/XMLHttpRequest.cpp:
+ (WebCore::XMLHttpRequest::responseBlob):
+
</ins><span class="cx"> 2016-03-30 Enrica Casucci <enrica@apple.com>
</span><span class="cx">
</span><span class="cx"> Add a style for Data Detectors links.
</span></span></pre></div>
<a id="trunkSourceWebCoreModulesfetchFetchBodycpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/fetch/FetchBody.cpp (198868 => 198869)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/fetch/FetchBody.cpp        2016-03-31 00:47:15 UTC (rev 198868)
+++ trunk/Source/WebCore/Modules/fetch/FetchBody.cpp        2016-03-31 01:21:04 UTC (rev 198869)
</span><span class="lines">@@ -201,7 +201,7 @@
</span><span class="cx"> ASSERT(type == Consumer::Type::ArrayBuffer || type == Consumer::Type::Blob);
</span><span class="cx">
</span><span class="cx"> if (type == Consumer::Type::ArrayBuffer) {
</span><del>- Vector<char> data = extractFromText();
</del><ins>+ Vector<uint8_t> data = extractFromText();
</ins><span class="cx"> fulfillPromiseWithArrayBuffer(promise, data.data(), data.size());
</span><span class="cx"> return;
</span><span class="cx"> }
</span><span class="lines">@@ -232,12 +232,12 @@
</span><span class="cx"> owner.loadBlob(*m_blob, loadingType(type));
</span><span class="cx"> }
</span><span class="cx">
</span><del>-Vector<char> FetchBody::extractFromText() const
</del><ins>+Vector<uint8_t> FetchBody::extractFromText() const
</ins><span class="cx"> {
</span><span class="cx"> ASSERT(m_type == Type::Text);
</span><span class="cx"> // FIXME: This double allocation is not efficient. Might want to fix that at WTFString level.
</span><span class="cx"> CString data = m_text.utf8();
</span><del>- Vector<char> value(data.length());
</del><ins>+ Vector<uint8_t> value(data.length());
</ins><span class="cx"> memcpy(value.data(), data.data(), data.length());
</span><span class="cx"> return value;
</span><span class="cx"> }
</span><span class="lines">@@ -245,10 +245,10 @@
</span><span class="cx"> static inline RefPtr<Blob> blobFromArrayBuffer(ArrayBuffer* buffer, const String& contentType)
</span><span class="cx"> {
</span><span class="cx"> if (!buffer)
</span><del>- return Blob::create(Vector<char>(), contentType);
</del><ins>+ return Blob::create(Vector<uint8_t>(), contentType);
</ins><span class="cx">
</span><span class="cx"> // FIXME: We should try to move buffer to Blob without doing this copy.
</span><del>- Vector<char> value(buffer->byteLength());
</del><ins>+ Vector<uint8_t> value(buffer->byteLength());
</ins><span class="cx"> memcpy(value.data(), buffer->data(), buffer->byteLength());
</span><span class="cx"> return Blob::create(WTFMove(value), contentType);
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceWebCoreModulesfetchFetchBodyh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/fetch/FetchBody.h (198868 => 198869)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/fetch/FetchBody.h        2016-03-31 00:47:15 UTC (rev 198868)
+++ trunk/Source/WebCore/Modules/fetch/FetchBody.h        2016-03-31 01:21:04 UTC (rev 198869)
</span><span class="lines">@@ -87,7 +87,7 @@
</span><span class="cx"> };
</span><span class="cx"> void consume(FetchBodyOwner&, Consumer::Type, DeferredWrapper&&);
</span><span class="cx">
</span><del>- Vector<char> extractFromText() const;
</del><ins>+ Vector<uint8_t> extractFromText() const;
</ins><span class="cx"> bool processIfEmptyOrDisturbed(Consumer::Type, DeferredWrapper&);
</span><span class="cx"> void consumeArrayBuffer(Consumer::Type, DeferredWrapper&);
</span><span class="cx"> void consumeText(Consumer::Type, DeferredWrapper&);
</span></span></pre></div>
<a id="trunkSourceWebCoreModuleswebsocketsThreadableWebSocketChannelClientWrappercpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/websockets/ThreadableWebSocketChannelClientWrapper.cpp (198868 => 198869)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/websockets/ThreadableWebSocketChannelClientWrapper.cpp        2016-03-31 00:47:15 UTC (rev 198868)
+++ trunk/Source/WebCore/Modules/websockets/ThreadableWebSocketChannelClientWrapper.cpp        2016-03-31 01:21:04 UTC (rev 198869)
</span><span class="lines">@@ -180,10 +180,10 @@
</span><span class="cx"> processPendingTasks();
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void ThreadableWebSocketChannelClientWrapper::didReceiveBinaryData(Vector<char>&& binaryData)
</del><ins>+void ThreadableWebSocketChannelClientWrapper::didReceiveBinaryData(Vector<uint8_t>&& binaryData)
</ins><span class="cx"> {
</span><span class="cx"> ref();
</span><del>- Vector<char>* capturedData = new Vector<char>(WTFMove(binaryData));
</del><ins>+ Vector<uint8_t>* capturedData = new Vector<uint8_t>(WTFMove(binaryData));
</ins><span class="cx"> m_pendingTasks.append(std::make_unique<ScriptExecutionContext::Task>([this, capturedData] (ScriptExecutionContext&) {
</span><span class="cx"> if (m_client)
</span><span class="cx"> m_client->didReceiveBinaryData(WTFMove(*capturedData));
</span></span></pre></div>
<a id="trunkSourceWebCoreModuleswebsocketsThreadableWebSocketChannelClientWrapperh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/websockets/ThreadableWebSocketChannelClientWrapper.h (198868 => 198869)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/websockets/ThreadableWebSocketChannelClientWrapper.h        2016-03-31 00:47:15 UTC (rev 198868)
+++ trunk/Source/WebCore/Modules/websockets/ThreadableWebSocketChannelClientWrapper.h        2016-03-31 01:21:04 UTC (rev 198869)
</span><span class="lines">@@ -79,7 +79,7 @@
</span><span class="cx">
</span><span class="cx"> void didConnect();
</span><span class="cx"> void didReceiveMessage(const String& message);
</span><del>- void didReceiveBinaryData(Vector<char>&&);
</del><ins>+ void didReceiveBinaryData(Vector<uint8_t>&&);
</ins><span class="cx"> void didUpdateBufferedAmount(unsigned long bufferedAmount);
</span><span class="cx"> void didStartClosingHandshake();
</span><span class="cx"> void didClose(unsigned long unhandledBufferedAmount, WebSocketChannelClient::ClosingHandshakeCompletionStatus, unsigned short code, const String& reason);
</span></span></pre></div>
<a id="trunkSourceWebCoreModuleswebsocketsWebSocketcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/websockets/WebSocket.cpp (198868 => 198869)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/websockets/WebSocket.cpp        2016-03-31 00:47:15 UTC (rev 198868)
+++ trunk/Source/WebCore/Modules/websockets/WebSocket.cpp        2016-03-31 01:21:04 UTC (rev 198869)
</span><span class="lines">@@ -561,7 +561,7 @@
</span><span class="cx"> dispatchEvent(MessageEvent::create(msg, SecurityOrigin::create(m_url)->toString()));
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void WebSocket::didReceiveBinaryData(Vector<char>&& binaryData)
</del><ins>+void WebSocket::didReceiveBinaryData(Vector<uint8_t>&& binaryData)
</ins><span class="cx"> {
</span><span class="cx"> LOG(Network, "WebSocket %p didReceiveBinaryData() %lu byte binary message", this, static_cast<unsigned long>(binaryData.size()));
</span><span class="cx"> switch (m_binaryType) {
</span></span></pre></div>
<a id="trunkSourceWebCoreModuleswebsocketsWebSocketh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/websockets/WebSocket.h (198868 => 198869)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/websockets/WebSocket.h        2016-03-31 00:47:15 UTC (rev 198868)
+++ trunk/Source/WebCore/Modules/websockets/WebSocket.h        2016-03-31 01:21:04 UTC (rev 198869)
</span><span class="lines">@@ -100,7 +100,7 @@
</span><span class="cx"> // WebSocketChannelClient functions.
</span><span class="cx"> void didConnect() override;
</span><span class="cx"> void didReceiveMessage(const String& message) override;
</span><del>- void didReceiveBinaryData(Vector<char>&&) override;
</del><ins>+ void didReceiveBinaryData(Vector<uint8_t>&&) override;
</ins><span class="cx"> void didReceiveMessageError() override;
</span><span class="cx"> void didUpdateBufferedAmount(unsigned long bufferedAmount) override;
</span><span class="cx"> void didStartClosingHandshake() override;
</span></span></pre></div>
<a id="trunkSourceWebCoreModuleswebsocketsWebSocketChannelcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/websockets/WebSocketChannel.cpp (198868 => 198869)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/websockets/WebSocketChannel.cpp        2016-03-31 00:47:15 UTC (rev 198868)
+++ trunk/Source/WebCore/Modules/websockets/WebSocketChannel.cpp        2016-03-31 01:21:04 UTC (rev 198869)
</span><span class="lines">@@ -586,7 +586,7 @@
</span><span class="cx"> // so we should pretend that we have finished to read this frame and
</span><span class="cx"> // make sure that the member variables are in a consistent state before
</span><span class="cx"> // the handler is invoked.
</span><del>- Vector<char> continuousFrameData = WTFMove(m_continuousFrameData);
</del><ins>+ Vector<uint8_t> continuousFrameData = WTFMove(m_continuousFrameData);
</ins><span class="cx"> m_hasContinuousFrame = false;
</span><span class="cx"> if (m_continuousFrameOpCode == WebSocketFrame::OpCodeText) {
</span><span class="cx"> String message;
</span><span class="lines">@@ -626,7 +626,7 @@
</span><span class="cx">
</span><span class="cx"> case WebSocketFrame::OpCodeBinary:
</span><span class="cx"> if (frame.final) {
</span><del>- Vector<char> binaryData(frame.payloadLength);
</del><ins>+ Vector<uint8_t> binaryData(frame.payloadLength);
</ins><span class="cx"> memcpy(binaryData.data(), frame.payload, frame.payloadLength);
</span><span class="cx"> skipBuffer(frameEnd - m_buffer.data());
</span><span class="cx"> m_client->didReceiveBinaryData(WTFMove(binaryData));
</span></span></pre></div>
<a id="trunkSourceWebCoreModuleswebsocketsWebSocketChannelh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/websockets/WebSocketChannel.h (198868 => 198869)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/websockets/WebSocketChannel.h        2016-03-31 00:47:15 UTC (rev 198868)
+++ trunk/Source/WebCore/Modules/websockets/WebSocketChannel.h        2016-03-31 01:21:04 UTC (rev 198869)
</span><span class="lines">@@ -204,7 +204,7 @@
</span><span class="cx"> // Private members only for hybi-10 protocol.
</span><span class="cx"> bool m_hasContinuousFrame;
</span><span class="cx"> WebSocketFrame::OpCode m_continuousFrameOpCode;
</span><del>- Vector<char> m_continuousFrameData;
</del><ins>+ Vector<uint8_t> m_continuousFrameData;
</ins><span class="cx"> unsigned short m_closeEventCode;
</span><span class="cx"> String m_closeEventReason;
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCoreModuleswebsocketsWebSocketChannelClienth"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/websockets/WebSocketChannelClient.h (198868 => 198869)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/websockets/WebSocketChannelClient.h        2016-03-31 00:47:15 UTC (rev 198868)
+++ trunk/Source/WebCore/Modules/websockets/WebSocketChannelClient.h        2016-03-31 01:21:04 UTC (rev 198869)
</span><span class="lines">@@ -43,7 +43,7 @@
</span><span class="cx"> virtual ~WebSocketChannelClient() { }
</span><span class="cx"> virtual void didConnect() { }
</span><span class="cx"> virtual void didReceiveMessage(const String&) { }
</span><del>- virtual void didReceiveBinaryData(Vector<char>&&) { }
</del><ins>+ virtual void didReceiveBinaryData(Vector<uint8_t>&&) { }
</ins><span class="cx"> virtual void didReceiveMessageError() { }
</span><span class="cx"> virtual void didUpdateBufferedAmount(unsigned long /* bufferedAmount */) { }
</span><span class="cx"> virtual void didStartClosingHandshake() { }
</span></span></pre></div>
<a id="trunkSourceWebCoreModuleswebsocketsWorkerThreadableWebSocketChannelcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/websockets/WorkerThreadableWebSocketChannel.cpp (198868 => 198869)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/websockets/WorkerThreadableWebSocketChannel.cpp        2016-03-31 00:47:15 UTC (rev 198868)
+++ trunk/Source/WebCore/Modules/websockets/WorkerThreadableWebSocketChannel.cpp        2016-03-31 01:21:04 UTC (rev 198869)
</span><span class="lines">@@ -288,12 +288,12 @@
</span><span class="cx"> }, m_taskMode);
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void WorkerThreadableWebSocketChannel::Peer::didReceiveBinaryData(Vector<char>&& binaryData)
</del><ins>+void WorkerThreadableWebSocketChannel::Peer::didReceiveBinaryData(Vector<uint8_t>&& binaryData)
</ins><span class="cx"> {
</span><span class="cx"> ASSERT(isMainThread());
</span><span class="cx">
</span><span class="cx"> RefPtr<ThreadableWebSocketChannelClientWrapper> workerClientWrapper = m_workerClientWrapper;
</span><del>- Vector<char>* capturedData = new Vector<char>(WTFMove(binaryData));
</del><ins>+ Vector<uint8_t>* capturedData = new Vector<uint8_t>(WTFMove(binaryData));
</ins><span class="cx"> m_loaderProxy.postTaskForModeToWorkerGlobalScope([workerClientWrapper, capturedData] (ScriptExecutionContext& context) {
</span><span class="cx"> ASSERT_UNUSED(context, context.isWorkerGlobalScope());
</span><span class="cx"> workerClientWrapper->didReceiveBinaryData(WTFMove(*capturedData));
</span></span></pre></div>
<a id="trunkSourceWebCoreModuleswebsocketsWorkerThreadableWebSocketChannelh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/websockets/WorkerThreadableWebSocketChannel.h (198868 => 198869)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/websockets/WorkerThreadableWebSocketChannel.h        2016-03-31 00:47:15 UTC (rev 198868)
+++ trunk/Source/WebCore/Modules/websockets/WorkerThreadableWebSocketChannel.h        2016-03-31 01:21:04 UTC (rev 198869)
</span><span class="lines">@@ -100,7 +100,7 @@
</span><span class="cx"> // WebSocketChannelClient functions.
</span><span class="cx"> void didConnect() override;
</span><span class="cx"> void didReceiveMessage(const String& message) override;
</span><del>- void didReceiveBinaryData(Vector<char>&&) override;
</del><ins>+ void didReceiveBinaryData(Vector<uint8_t>&&) override;
</ins><span class="cx"> void didUpdateBufferedAmount(unsigned long bufferedAmount) override;
</span><span class="cx"> void didStartClosingHandshake() override;
</span><span class="cx"> void didClose(unsigned long unhandledBufferedAmount, ClosingHandshakeCompletionStatus, unsigned short code, const String& reason) override;
</span></span></pre></div>
<a id="trunkSourceWebCorefileapiBlobcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/fileapi/Blob.cpp (198868 => 198869)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/fileapi/Blob.cpp        2016-03-31 00:47:15 UTC (rev 198868)
+++ trunk/Source/WebCore/fileapi/Blob.cpp        2016-03-31 01:21:04 UTC (rev 198869)
</span><span class="lines">@@ -77,7 +77,7 @@
</span><span class="cx"> ThreadableBlobRegistry::registerBlobURL(m_internalURL, Vector<BlobPart>(), String());
</span><span class="cx"> }
</span><span class="cx">
</span><del>-Blob::Blob(Vector<char> data, const String& contentType)
</del><ins>+Blob::Blob(Vector<uint8_t> data, const String& contentType)
</ins><span class="cx"> : m_type(contentType)
</span><span class="cx"> , m_size(data.size())
</span><span class="cx"> {
</span></span></pre></div>
<a id="trunkSourceWebCorefileapiBlobh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/fileapi/Blob.h (198868 => 198869)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/fileapi/Blob.h        2016-03-31 00:47:15 UTC (rev 198868)
+++ trunk/Source/WebCore/fileapi/Blob.h        2016-03-31 01:21:04 UTC (rev 198869)
</span><span class="lines">@@ -48,7 +48,7 @@
</span><span class="cx"> return adoptRef(*new Blob);
</span><span class="cx"> }
</span><span class="cx">
</span><del>- static Ref<Blob> create(Vector<char> data, const String& contentType)
</del><ins>+ static Ref<Blob> create(Vector<uint8_t> data, const String& contentType)
</ins><span class="cx"> {
</span><span class="cx"> return adoptRef(*new Blob(WTFMove(data), contentType));
</span><span class="cx"> }
</span><span class="lines">@@ -91,7 +91,7 @@
</span><span class="cx">
</span><span class="cx"> protected:
</span><span class="cx"> Blob();
</span><del>- Blob(Vector<char>, const String& contentType);
</del><ins>+ Blob(Vector<uint8_t>, const String& contentType);
</ins><span class="cx"> Blob(Vector<BlobPart>, const String& contentType);
</span><span class="cx">
</span><span class="cx"> enum UninitializedContructor { uninitializedContructor };
</span></span></pre></div>
<a id="trunkSourceWebCorefileapiWebKitBlobBuilderh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/fileapi/WebKitBlobBuilder.h (198868 => 198869)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/fileapi/WebKitBlobBuilder.h        2016-03-31 00:47:15 UTC (rev 198868)
+++ trunk/Source/WebCore/fileapi/WebKitBlobBuilder.h        2016-03-31 01:21:04 UTC (rev 198869)
</span><span class="lines">@@ -55,7 +55,7 @@
</span><span class="cx">
</span><span class="cx"> private:
</span><span class="cx"> Vector<BlobPart> m_items;
</span><del>- Vector<char> m_appendableData;
</del><ins>+ Vector<uint8_t> m_appendableData;
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworkBlobDatacpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/BlobData.cpp (198868 => 198869)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/BlobData.cpp        2016-03-31 00:47:15 UTC (rev 198868)
+++ trunk/Source/WebCore/platform/network/BlobData.cpp        2016-03-31 01:21:04 UTC (rev 198869)
</span><span class="lines">@@ -39,6 +39,12 @@
</span><span class="cx">
</span><span class="cx"> namespace WebCore {
</span><span class="cx">
</span><ins>+BlobData::BlobData(const String& contentType)
+ : m_contentType(contentType)
+{
+ ASSERT(Blob::isNormalizedContentType(contentType));
+}
+
</ins><span class="cx"> const long long BlobDataItem::toEndOfFile = -1;
</span><span class="cx">
</span><span class="cx"> long long BlobDataItem::length() const
</span><span class="lines">@@ -46,31 +52,25 @@
</span><span class="cx"> if (m_length != toEndOfFile)
</span><span class="cx"> return m_length;
</span><span class="cx">
</span><del>- switch (type) {
- case Data:
</del><ins>+ switch (m_type) {
+ case Type::Data:
</ins><span class="cx"> ASSERT_NOT_REACHED();
</span><span class="cx"> return m_length;
</span><del>- case File:
- return file->size();
</del><ins>+ case Type::File:
+ return m_file->size();
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> ASSERT_NOT_REACHED();
</span><span class="cx"> return m_length;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void BlobData::setContentType(const String& contentType)
</del><ins>+void BlobData::appendData(const ThreadSafeDataBuffer& data)
</ins><span class="cx"> {
</span><del>- ASSERT(Blob::isNormalizedContentType(contentType));
- m_contentType = contentType;
-}
-
-void BlobData::appendData(PassRefPtr<RawData> data)
-{
- size_t dataSize = data->length();
</del><ins>+ size_t dataSize = data.data() ? data.data()->size() : 0;
</ins><span class="cx"> appendData(data, 0, dataSize);
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void BlobData::appendData(PassRefPtr<RawData> data, long long offset, long long length)
</del><ins>+void BlobData::appendData(const ThreadSafeDataBuffer& data, long long offset, long long length)
</ins><span class="cx"> {
</span><span class="cx"> m_items.append(BlobDataItem(data, offset, length));
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworkBlobDatah"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/BlobData.h (198868 => 198869)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/BlobData.h        2016-03-31 00:47:15 UTC (rev 198868)
+++ trunk/Source/WebCore/platform/network/BlobData.h        2016-03-31 01:21:04 UTC (rev 198869)
</span><span class="lines">@@ -32,52 +32,31 @@
</span><span class="cx"> #define BlobData_h
</span><span class="cx">
</span><span class="cx"> #include "BlobDataFileReference.h"
</span><ins>+#include "ThreadSafeDataBuffer.h"
</ins><span class="cx"> #include "URL.h"
</span><span class="cx"> #include <wtf/Forward.h>
</span><span class="cx"> #include <wtf/RefCounted.h>
</span><ins>+#include <wtf/ThreadSafeRefCounted.h>
</ins><span class="cx"> #include <wtf/text/WTFString.h>
</span><span class="cx">
</span><span class="cx"> namespace WebCore {
</span><span class="cx">
</span><del>-class RawData : public RefCounted<RawData> {
</del><ins>+class BlobDataItem {
</ins><span class="cx"> public:
</span><del>- static Ref<RawData> create(Vector<char>&& data)
- {
- return adoptRef(*new RawData(WTFMove(data)));
- }
-
- static Ref<RawData> create(const char* data, size_t size)
- {
- Vector<char> dataVector(size);
- memcpy(dataVector.data(), data, size);
- return adoptRef(*new RawData(WTFMove(dataVector)));
- }
-
- const char* data() const { return m_data.data(); }
- size_t length() const { return m_data.size(); }
-
-private:
- RawData(Vector<char>&& data)
- : m_data(WTFMove(data))
- {
- }
-
- Vector<char> m_data;
-};
-
-struct BlobDataItem {
</del><span class="cx"> WEBCORE_EXPORT static const long long toEndOfFile;
</span><span class="cx">
</span><del>- enum {
</del><ins>+ enum class Type {
</ins><span class="cx"> Data,
</span><span class="cx"> File
</span><del>- } type;
</del><ins>+ };
</ins><span class="cx">
</span><ins>+ Type type() const { return m_type; }
+
</ins><span class="cx"> // For Data type.
</span><del>- RefPtr<RawData> data;
</del><ins>+ const ThreadSafeDataBuffer& data() const { return m_data; }
</ins><span class="cx">
</span><span class="cx"> // For File type.
</span><del>- RefPtr<BlobDataFileReference> file;
</del><ins>+ BlobDataFileReference* file() const { return m_file.get(); }
</ins><span class="cx">
</span><span class="cx"> long long offset() const { return m_offset; }
</span><span class="cx"> long long length() const; // Computes file length if it's not known yet.
</span><span class="lines">@@ -86,55 +65,59 @@
</span><span class="cx"> friend class BlobData;
</span><span class="cx">
</span><span class="cx"> explicit BlobDataItem(PassRefPtr<BlobDataFileReference> file)
</span><del>- : type(File)
- , file(file)
</del><ins>+ : m_type(Type::File)
+ , m_file(file)
</ins><span class="cx"> , m_offset(0)
</span><span class="cx"> , m_length(toEndOfFile)
</span><span class="cx"> {
</span><span class="cx"> }
</span><span class="cx">
</span><del>- BlobDataItem(PassRefPtr<RawData> data, long long offset, long long length)
- : type(Data)
- , data(data)
</del><ins>+ BlobDataItem(ThreadSafeDataBuffer data, long long offset, long long length)
+ : m_type(Type::Data)
+ , m_data(data)
</ins><span class="cx"> , m_offset(offset)
</span><span class="cx"> , m_length(length)
</span><span class="cx"> {
</span><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> BlobDataItem(BlobDataFileReference* file, long long offset, long long length)
</span><del>- : type(File)
- , file(file)
</del><ins>+ : m_type(Type::File)
+ , m_file(file)
</ins><span class="cx"> , m_offset(offset)
</span><span class="cx"> , m_length(length)
</span><span class="cx"> {
</span><span class="cx"> }
</span><span class="cx">
</span><ins>+ Type m_type;
+ ThreadSafeDataBuffer m_data;
+ RefPtr<BlobDataFileReference> m_file;
+
</ins><span class="cx"> long long m_offset;
</span><span class="cx"> long long m_length;
</span><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> typedef Vector<BlobDataItem> BlobDataItemList;
</span><span class="cx">
</span><del>-class BlobData : public RefCounted<BlobData> {
</del><ins>+class BlobData : public ThreadSafeRefCounted<BlobData> {
</ins><span class="cx"> public:
</span><del>- static Ref<BlobData> create()
</del><ins>+ static Ref<BlobData> create(const String& contentType)
</ins><span class="cx"> {
</span><del>- return adoptRef(*new BlobData);
</del><ins>+ return adoptRef(*new BlobData(contentType));
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> const String& contentType() const { return m_contentType; }
</span><del>- WEBCORE_EXPORT void setContentType(const String&);
</del><span class="cx">
</span><span class="cx"> const BlobDataItemList& items() const { return m_items; }
</span><span class="cx"> void swapItems(BlobDataItemList&);
</span><span class="cx">
</span><del>- void appendData(PassRefPtr<RawData>);
</del><ins>+ void appendData(const ThreadSafeDataBuffer&);
</ins><span class="cx"> void appendFile(PassRefPtr<BlobDataFileReference>);
</span><span class="cx">
</span><span class="cx"> private:
</span><span class="cx"> friend class BlobRegistryImpl;
</span><ins>+ BlobData(const String& contentType);
</ins><span class="cx">
</span><del>- void appendData(PassRefPtr<RawData>, long long offset, long long length);
</del><ins>+ void appendData(const ThreadSafeDataBuffer&, long long offset, long long length);
</ins><span class="cx"> void appendFile(BlobDataFileReference*, long long offset, long long length);
</span><span class="cx">
</span><span class="cx"> String m_contentType;
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworkBlobParth"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/BlobPart.h (198868 => 198869)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/BlobPart.h        2016-03-31 00:47:15 UTC (rev 198868)
+++ trunk/Source/WebCore/platform/network/BlobPart.h        2016-03-31 01:21:04 UTC (rev 198869)
</span><span class="lines">@@ -42,7 +42,7 @@
</span><span class="cx"> {
</span><span class="cx"> }
</span><span class="cx">
</span><del>- BlobPart(Vector<char> data)
</del><ins>+ BlobPart(Vector<uint8_t> data)
</ins><span class="cx"> : m_type(Data)
</span><span class="cx"> , m_data(WTFMove(data))
</span><span class="cx"> {
</span><span class="lines">@@ -56,13 +56,13 @@
</span><span class="cx">
</span><span class="cx"> Type type() const { return m_type; }
</span><span class="cx">
</span><del>- const Vector<char>& data() const
</del><ins>+ const Vector<uint8_t>& data() const
</ins><span class="cx"> {
</span><span class="cx"> ASSERT(m_type == Data);
</span><span class="cx"> return m_data;
</span><span class="cx"> }
</span><span class="cx">
</span><del>- Vector<char> moveData()
</del><ins>+ Vector<uint8_t> moveData()
</ins><span class="cx"> {
</span><span class="cx"> ASSERT(m_type == Data);
</span><span class="cx"> return WTFMove(m_data);
</span><span class="lines">@@ -81,7 +81,7 @@
</span><span class="cx">
</span><span class="cx"> private:
</span><span class="cx"> Type m_type;
</span><del>- Vector<char> m_data;
</del><ins>+ Vector<uint8_t> m_data;
</ins><span class="cx"> URL m_url;
</span><span class="cx"> };
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworkBlobRegistryImplcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/BlobRegistryImpl.cpp (198868 => 198869)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/BlobRegistryImpl.cpp        2016-03-31 00:47:15 UTC (rev 198868)
+++ trunk/Source/WebCore/platform/network/BlobRegistryImpl.cpp        2016-03-31 01:21:04 UTC (rev 198869)
</span><span class="lines">@@ -98,11 +98,11 @@
</span><span class="cx"> for (; iter != items.end() && length > 0; ++iter) {
</span><span class="cx"> long long currentLength = iter->length() - offset;
</span><span class="cx"> long long newLength = currentLength > length ? length : currentLength;
</span><del>- if (iter->type == BlobDataItem::Data)
- blobData->appendData(iter->data, iter->offset() + offset, newLength);
</del><ins>+ if (iter->type() == BlobDataItem::Type::Data)
+ blobData->appendData(iter->data(), iter->offset() + offset, newLength);
</ins><span class="cx"> else {
</span><del>- ASSERT(iter->type == BlobDataItem::File);
- blobData->appendFile(iter->file.get(), iter->offset() + offset, newLength);
</del><ins>+ ASSERT(iter->type() == BlobDataItem::Type::File);
+ blobData->appendFile(iter->file(), iter->offset() + offset, newLength);
</ins><span class="cx"> }
</span><span class="cx"> length -= newLength;
</span><span class="cx"> offset = 0;
</span><span class="lines">@@ -115,8 +115,7 @@
</span><span class="cx"> ASSERT(isMainThread());
</span><span class="cx"> registerBlobResourceHandleConstructor();
</span><span class="cx">
</span><del>- RefPtr<BlobData> blobData = BlobData::create();
- blobData->setContentType(contentType);
</del><ins>+ RefPtr<BlobData> blobData = BlobData::create(contentType);
</ins><span class="cx">
</span><span class="cx"> blobData->appendFile(file);
</span><span class="cx"> m_blobs.set(url.string(), blobData.release());
</span><span class="lines">@@ -127,8 +126,7 @@
</span><span class="cx"> ASSERT(isMainThread());
</span><span class="cx"> registerBlobResourceHandleConstructor();
</span><span class="cx">
</span><del>- RefPtr<BlobData> blobData = BlobData::create();
- blobData->setContentType(contentType);
</del><ins>+ RefPtr<BlobData> blobData = BlobData::create(contentType);
</ins><span class="cx">
</span><span class="cx"> // The blob data is stored in the "canonical" way. That is, it only contains a list of Data and File items.
</span><span class="cx"> // 1) The Data item is denoted by the raw data and the range.
</span><span class="lines">@@ -139,8 +137,9 @@
</span><span class="cx"> for (BlobPart& part : blobParts) {
</span><span class="cx"> switch (part.type()) {
</span><span class="cx"> case BlobPart::Data: {
</span><del>- RefPtr<RawData> rawData = RawData::create(part.moveData());
- blobData->appendData(rawData.release());
</del><ins>+ auto movedData = part.moveData();
+ auto data = ThreadSafeDataBuffer::adoptVector(movedData);
+ blobData->appendData(data);
</ins><span class="cx"> break;
</span><span class="cx"> }
</span><span class="cx"> case BlobPart::Blob: {
</span><span class="lines">@@ -196,8 +195,7 @@
</span><span class="cx"> end = originalSize;
</span><span class="cx">
</span><span class="cx"> unsigned long long newLength = end - start;
</span><del>- RefPtr<BlobData> newData = BlobData::create();
- newData->setContentType(originalData->contentType());
</del><ins>+ RefPtr<BlobData> newData = BlobData::create(originalData->contentType());
</ins><span class="cx">
</span><span class="cx"> appendStorageItems(newData.get(), originalData->items(), start, newLength);
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworkBlobResourceHandlecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/BlobResourceHandle.cpp (198868 => 198869)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/BlobResourceHandle.cpp        2016-03-31 00:47:15 UTC (rev 198868)
+++ trunk/Source/WebCore/platform/network/BlobResourceHandle.cpp        2016-03-31 01:21:04 UTC (rev 198869)
</span><span class="lines">@@ -253,16 +253,16 @@
</span><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> const BlobDataItem& item = m_blobData->items().at(m_sizeItemCount);
</span><del>- switch (item.type) {
- case BlobDataItem::Data:
</del><ins>+ switch (item.type()) {
+ case BlobDataItem::Type::Data:
</ins><span class="cx"> didGetSize(item.length());
</span><span class="cx"> break;
</span><del>- case BlobDataItem::File:
</del><ins>+ case BlobDataItem::Type::File:
</ins><span class="cx"> // Files know their sizes, but asking the stream to verify that the file wasn't modified.
</span><span class="cx"> if (m_async)
</span><del>- m_asyncStream->getSize(item.file->path(), item.file->expectedModificationTime());
</del><ins>+ m_asyncStream->getSize(item.file()->path(), item.file()->expectedModificationTime());
</ins><span class="cx"> else
</span><del>- didGetSize(m_stream->getSize(item.file->path(), item.file->expectedModificationTime()));
</del><ins>+ didGetSize(m_stream->getSize(item.file()->path(), item.file()->expectedModificationTime()));
</ins><span class="cx"> break;
</span><span class="cx"> default:
</span><span class="cx"> ASSERT_NOT_REACHED();
</span><span class="lines">@@ -351,9 +351,9 @@
</span><span class="cx">
</span><span class="cx"> const BlobDataItem& item = m_blobData->items().at(m_readItemCount);
</span><span class="cx"> int bytesRead = 0;
</span><del>- if (item.type == BlobDataItem::Data)
</del><ins>+ if (item.type() == BlobDataItem::Type::Data)
</ins><span class="cx"> bytesRead = readDataSync(item, buf + offset, remaining);
</span><del>- else if (item.type == BlobDataItem::File)
</del><ins>+ else if (item.type() == BlobDataItem::Type::File)
</ins><span class="cx"> bytesRead = readFileSync(item, buf + offset, remaining);
</span><span class="cx"> else
</span><span class="cx"> ASSERT_NOT_REACHED();
</span><span class="lines">@@ -389,7 +389,7 @@
</span><span class="cx"> int bytesToRead = (length > remaining) ? static_cast<int>(remaining) : length;
</span><span class="cx"> if (bytesToRead > m_totalRemainingSize)
</span><span class="cx"> bytesToRead = static_cast<int>(m_totalRemainingSize);
</span><del>- memcpy(buf, item.data->data() + item.offset() + m_currentItemReadSize, bytesToRead);
</del><ins>+ memcpy(buf, item.data().data() + item.offset() + m_currentItemReadSize, bytesToRead);
</ins><span class="cx"> m_totalRemainingSize -= bytesToRead;
</span><span class="cx">
</span><span class="cx"> m_currentItemReadSize += bytesToRead;
</span><span class="lines">@@ -411,7 +411,7 @@
</span><span class="cx"> long long bytesToRead = m_itemLengthList[m_readItemCount] - m_currentItemReadSize;
</span><span class="cx"> if (bytesToRead > m_totalRemainingSize)
</span><span class="cx"> bytesToRead = m_totalRemainingSize;
</span><del>- bool success = m_stream->openForRead(item.file->path(), item.offset() + m_currentItemReadSize, bytesToRead);
</del><ins>+ bool success = m_stream->openForRead(item.file()->path(), item.offset() + m_currentItemReadSize, bytesToRead);
</ins><span class="cx"> m_currentItemReadSize = 0;
</span><span class="cx"> if (!success) {
</span><span class="cx"> m_errorCode = notReadableError;
</span><span class="lines">@@ -452,9 +452,9 @@
</span><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> const BlobDataItem& item = m_blobData->items().at(m_readItemCount);
</span><del>- if (item.type == BlobDataItem::Data)
</del><ins>+ if (item.type() == BlobDataItem::Type::Data)
</ins><span class="cx"> readDataAsync(item);
</span><del>- else if (item.type == BlobDataItem::File)
</del><ins>+ else if (item.type() == BlobDataItem::Type::File)
</ins><span class="cx"> readFileAsync(item);
</span><span class="cx"> else
</span><span class="cx"> ASSERT_NOT_REACHED();
</span><span class="lines">@@ -464,12 +464,14 @@
</span><span class="cx"> {
</span><span class="cx"> ASSERT(isMainThread());
</span><span class="cx"> ASSERT(m_async);
</span><ins>+ ASSERT(item.data().data());
+
</ins><span class="cx"> Ref<BlobResourceHandle> protect(*this);
</span><span class="cx">
</span><span class="cx"> long long bytesToRead = item.length() - m_currentItemReadSize;
</span><span class="cx"> if (bytesToRead > m_totalRemainingSize)
</span><span class="cx"> bytesToRead = m_totalRemainingSize;
</span><del>- consumeData(item.data->data() + item.offset() + m_currentItemReadSize, static_cast<int>(bytesToRead));
</del><ins>+ consumeData(reinterpret_cast<const char*>(item.data().data()->data()) + item.offset() + m_currentItemReadSize, static_cast<int>(bytesToRead));
</ins><span class="cx"> m_currentItemReadSize = 0;
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -486,7 +488,7 @@
</span><span class="cx"> long long bytesToRead = m_itemLengthList[m_readItemCount] - m_currentItemReadSize;
</span><span class="cx"> if (bytesToRead > m_totalRemainingSize)
</span><span class="cx"> bytesToRead = static_cast<int>(m_totalRemainingSize);
</span><del>- m_asyncStream->openForRead(item.file->path(), item.offset() + m_currentItemReadSize, bytesToRead);
</del><ins>+ m_asyncStream->openForRead(item.file()->path(), item.offset() + m_currentItemReadSize, bytesToRead);
</ins><span class="cx"> m_fileOpened = true;
</span><span class="cx"> m_currentItemReadSize = 0;
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworkBlobResourceHandleh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/BlobResourceHandle.h (198868 => 198869)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/BlobResourceHandle.h        2016-03-31 00:47:15 UTC (rev 198868)
+++ trunk/Source/WebCore/platform/network/BlobResourceHandle.h        2016-03-31 01:21:04 UTC (rev 198869)
</span><span class="lines">@@ -44,7 +44,7 @@
</span><span class="cx"> class FileStream;
</span><span class="cx"> class ResourceHandleClient;
</span><span class="cx"> class ResourceRequest;
</span><del>-struct BlobDataItem;
</del><ins>+class BlobDataItem;
</ins><span class="cx">
</span><span class="cx"> class BlobResourceHandle final : public FileStreamClient, public ResourceHandle {
</span><span class="cx"> public:
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworkFormDatacpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/FormData.cpp (198868 => 198869)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/FormData.cpp        2016-03-31 00:47:15 UTC (rev 198868)
+++ trunk/Source/WebCore/platform/network/FormData.cpp        2016-03-31 01:21:04 UTC (rev 198869)
</span><span class="lines">@@ -293,10 +293,11 @@
</span><span class="cx"> const BlobDataItemList::const_iterator itend = blobData->items().end();
</span><span class="cx"> for (; it != itend; ++it) {
</span><span class="cx"> const BlobDataItem& blobItem = *it;
</span><del>- if (blobItem.type == BlobDataItem::Data)
- formData->appendData(blobItem.data->data() + static_cast<int>(blobItem.offset()), static_cast<int>(blobItem.length()));
- else if (blobItem.type == BlobDataItem::File)
- formData->appendFileRange(blobItem.file->path(), blobItem.offset(), blobItem.length(), blobItem.file->expectedModificationTime());
</del><ins>+ if (blobItem.type() == BlobDataItem::Type::Data) {
+ ASSERT(blobItem.data().data());
+ formData->appendData(blobItem.data().data()->data() + static_cast<int>(blobItem.offset()), static_cast<int>(blobItem.length()));
+ } else if (blobItem.type() == BlobDataItem::Type::File)
+ formData->appendFileRange(blobItem.file()->path(), blobItem.offset(), blobItem.length(), blobItem.file()->expectedModificationTime());
</ins><span class="cx"> else
</span><span class="cx"> ASSERT_NOT_REACHED();
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformnetworksoupResourceHandleSoupcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/network/soup/ResourceHandleSoup.cpp (198868 => 198869)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/network/soup/ResourceHandleSoup.cpp        2016-03-31 00:47:15 UTC (rev 198868)
+++ trunk/Source/WebCore/platform/network/soup/ResourceHandleSoup.cpp        2016-03-31 01:21:04 UTC (rev 198869)
</span><span class="lines">@@ -769,30 +769,30 @@
</span><span class="cx">
</span><span class="cx"> static bool blobIsOutOfDate(const BlobDataItem& blobItem)
</span><span class="cx"> {
</span><del>- ASSERT(blobItem.type == BlobDataItem::File);
- if (!isValidFileTime(blobItem.file->expectedModificationTime()))
</del><ins>+ ASSERT(blobItem.type == BlobDataItem::Type::File);
+ if (!isValidFileTime(blobItem.file()->expectedModificationTime()))
</ins><span class="cx"> return false;
</span><span class="cx">
</span><span class="cx"> time_t fileModificationTime;
</span><del>- if (!getFileModificationTime(blobItem.file->path(), fileModificationTime))
</del><ins>+ if (!getFileModificationTime(blobItem.file()->path(), fileModificationTime))
</ins><span class="cx"> return true;
</span><span class="cx">
</span><del>- return fileModificationTime != static_cast<time_t>(blobItem.file->expectedModificationTime());
</del><ins>+ return fileModificationTime != static_cast<time_t>(blobItem.file()->expectedModificationTime());
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> static void addEncodedBlobItemToSoupMessageBody(SoupMessage* message, const BlobDataItem& blobItem, unsigned long& totalBodySize)
</span><span class="cx"> {
</span><del>- if (blobItem.type == BlobDataItem::Data) {
</del><ins>+ if (blobItem.type() == BlobDataItem::Type::Data) {
</ins><span class="cx"> totalBodySize += blobItem.length();
</span><del>- soup_message_body_append(message->request_body, SOUP_MEMORY_TEMPORARY, blobItem.data->data() + blobItem.offset(), blobItem.length());
</del><ins>+ soup_message_body_append(message->request_body, SOUP_MEMORY_TEMPORARY, blobItem.data().data()->data() + blobItem.offset(), blobItem.length());
</ins><span class="cx"> return;
</span><span class="cx"> }
</span><span class="cx">
</span><del>- ASSERT(blobItem.type == BlobDataItem::File);
</del><ins>+ ASSERT(blobItem.type == BlobDataItem::Type::File);
</ins><span class="cx"> if (blobIsOutOfDate(blobItem))
</span><span class="cx"> return;
</span><span class="cx">
</span><del>- addFileToSoupMessageBody(message, blobItem.file->path(), blobItem.offset(), blobItem.length() == BlobDataItem::toEndOfFile ? 0 : blobItem.length(), totalBodySize);
</del><ins>+ addFileToSoupMessageBody(message, blobItem.file()->path(), blobItem.offset(), blobItem.length() == BlobDataItem::toEndOfFile ? 0 : blobItem.length(), totalBodySize);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> static void addEncodedBlobToSoupMessageBody(SoupMessage* message, const FormDataElement& element, unsigned long& totalBodySize)
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformtextLineEndingcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/text/LineEnding.cpp (198868 => 198869)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/text/LineEnding.cpp        2016-03-31 00:47:15 UTC (rev 198868)
+++ trunk/Source/WebCore/platform/text/LineEnding.cpp        2016-03-31 01:21:04 UTC (rev 198869)
</span><span class="lines">@@ -153,10 +153,8 @@
</span><span class="cx">
</span><span class="cx"> namespace WebCore {
</span><span class="cx">
</span><del>-void normalizeToCROrLF(const CString& from, Vector<char>& result, bool toCR);
-
</del><span class="cx"> // Normalize all line-endings to CR or LF.
</span><del>-void normalizeToCROrLF(const CString& from, Vector<char>& result, bool toCR)
</del><ins>+static void normalizeToCROrLF(const CString& from, Vector<uint8_t>& result, bool toCR)
</ins><span class="cx"> {
</span><span class="cx"> // Compute the new length.
</span><span class="cx"> size_t newLen = 0;
</span><span class="lines">@@ -181,7 +179,7 @@
</span><span class="cx"> p = from.data();
</span><span class="cx"> size_t oldResultSize = result.size();
</span><span class="cx"> result.grow(oldResultSize + newLen);
</span><del>- char* q = result.data() + oldResultSize;
</del><ins>+ uint8_t* q = result.data() + oldResultSize;
</ins><span class="cx">
</span><span class="cx"> // If no need to fix the string, just copy the string over.
</span><span class="cx"> if (!needFix) {
</span><span class="lines">@@ -214,23 +212,13 @@
</span><span class="cx"> return buffer.buffer();
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void normalizeLineEndingsToCR(const CString& from, Vector<char>& result)
</del><ins>+void normalizeLineEndingsToNative(const CString& from, Vector<uint8_t>& result)
</ins><span class="cx"> {
</span><del>- normalizeToCROrLF(from, result, true);
-}
-
-void normalizeLineEndingsToLF(const CString& from, Vector<char>& result)
-{
- normalizeToCROrLF(from, result, false);
-}
-
-void normalizeLineEndingsToNative(const CString& from, Vector<char>& result)
-{
</del><span class="cx"> #if OS(WINDOWS)
</span><span class="cx"> VectorCharAppendBuffer buffer(result);
</span><span class="cx"> internalNormalizeLineEndingsToCRLF(from, buffer);
</span><span class="cx"> #else
</span><del>- normalizeLineEndingsToLF(from, result);
</del><ins>+ normalizeToCROrLF(from, result, false);
</ins><span class="cx"> #endif
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformtextLineEndingh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/text/LineEnding.h (198868 => 198869)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/text/LineEnding.h        2016-03-31 00:47:15 UTC (rev 198868)
+++ trunk/Source/WebCore/platform/text/LineEnding.h        2016-03-31 01:21:04 UTC (rev 198869)
</span><span class="lines">@@ -40,15 +40,9 @@
</span><span class="cx"> // Normalize all line-endings in the given string to CRLF.
</span><span class="cx"> CString normalizeLineEndingsToCRLF(const CString& from);
</span><span class="cx">
</span><del>-// Normalize all line-endings in the given string to CR and append the result to the given buffer.
-void normalizeLineEndingsToCR(const CString& from, Vector<char>& result);
-
-// Normalize all line-endings in the given string to LF and append the result to the given buffer.
-void normalizeLineEndingsToLF(const CString& from, Vector<char>& result);
-
</del><span class="cx"> // Normalize all line-endings in the given string to the native line-endings and append the result to the given buffer.
</span><span class="cx"> // (Normalize to CRLF on Windows and normalize to LF on all other platforms.)
</span><del>-void normalizeLineEndingsToNative(const CString& from, Vector<char>& result);
</del><ins>+void normalizeLineEndingsToNative(const CString& from, Vector<uint8_t>& result);
</ins><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCorexmlXMLHttpRequestcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/xml/XMLHttpRequest.cpp (198868 => 198869)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/xml/XMLHttpRequest.cpp        2016-03-31 00:47:15 UTC (rev 198868)
+++ trunk/Source/WebCore/xml/XMLHttpRequest.cpp        2016-03-31 01:21:04 UTC (rev 198869)
</span><span class="lines">@@ -238,7 +238,7 @@
</span><span class="cx"> if (!m_responseBlob) {
</span><span class="cx"> if (m_binaryResponseBuilder) {
</span><span class="cx"> // FIXME: We just received the data from NetworkProcess, and are sending it back. This is inefficient.
</span><del>- Vector<char> data;
</del><ins>+ Vector<uint8_t> data;
</ins><span class="cx"> data.append(m_binaryResponseBuilder->data(), m_binaryResponseBuilder->size());
</span><span class="cx"> String normalizedContentType = Blob::normalizedContentType(responseMIMEType()); // responseMIMEType defaults to text/xml which may be incorrect.
</span><span class="cx"> m_responseBlob = Blob::create(WTFMove(data), normalizedContentType);
</span></span></pre></div>
<a id="trunkSourceWebKit2ChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/ChangeLog (198868 => 198869)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/ChangeLog        2016-03-31 00:47:15 UTC (rev 198868)
+++ trunk/Source/WebKit2/ChangeLog        2016-03-31 01:21:04 UTC (rev 198869)
</span><span class="lines">@@ -1,3 +1,15 @@
</span><ins>+2016-03-30 Brady Eidson <beidson@apple.com>
+
+ Make BlobData use ThreadSafeSharedBuffer instead of RawData.
+ https://bugs.webkit.org/show_bug.cgi?id=156041
+
+ Reviewed by Alex Christensen.
+
+ * NetworkProcess/FileAPI/NetworkBlobRegistry.cpp:
+ (WebKit::NetworkBlobRegistry::filesInBlob):
+ * Shared/WebCoreArgumentCoders.cpp:
+ (IPC::ArgumentCoder<BlobPart>::decode):
+
</ins><span class="cx"> 2016-03-30 Daniel Bates <dabates@apple.com>
</span><span class="cx">
</span><span class="cx"> Unreviewed, rolling out r198856.
</span></span></pre></div>
<a id="trunkSourceWebKit2NetworkProcessFileAPINetworkBlobRegistrycpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/NetworkProcess/FileAPI/NetworkBlobRegistry.cpp (198868 => 198869)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/NetworkProcess/FileAPI/NetworkBlobRegistry.cpp        2016-03-31 00:47:15 UTC (rev 198868)
+++ trunk/Source/WebKit2/NetworkProcess/FileAPI/NetworkBlobRegistry.cpp        2016-03-31 01:21:04 UTC (rev 198869)
</span><span class="lines">@@ -141,8 +141,8 @@
</span><span class="cx">
</span><span class="cx"> Vector<RefPtr<BlobDataFileReference>> result;
</span><span class="cx"> for (const BlobDataItem& item : blobData->items()) {
</span><del>- if (item.type == BlobDataItem::File)
- result.append(item.file);
</del><ins>+ if (item.type() == BlobDataItem::Type::File)
+ result.append(item.file());
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> return result;
</span></span></pre></div>
<a id="trunkSourceWebKit2SharedWebCoreArgumentCoderscpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/Shared/WebCoreArgumentCoders.cpp (198868 => 198869)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/Shared/WebCoreArgumentCoders.cpp        2016-03-31 00:47:15 UTC (rev 198868)
+++ trunk/Source/WebKit2/Shared/WebCoreArgumentCoders.cpp        2016-03-31 01:21:04 UTC (rev 198869)
</span><span class="lines">@@ -1861,7 +1861,7 @@
</span><span class="cx">
</span><span class="cx"> switch (type) {
</span><span class="cx"> case BlobPart::Data: {
</span><del>- Vector<char> data;
</del><ins>+ Vector<uint8_t> data;
</ins><span class="cx"> if (!decoder.decode(data))
</span><span class="cx"> return false;
</span><span class="cx"> blobPart = BlobPart(WTFMove(data));
</span></span></pre>
</div>
</div>
</body>
</html>