Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(194)

Side by Side Diff: third_party/WebKit/Source/modules/serviceworkers/ServiceWorkerClient.cpp

Issue 1979953002: Remove OwnPtr::release() calls in modules/ (part 3). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "modules/serviceworkers/ServiceWorkerClient.h" 5 #include "modules/serviceworkers/ServiceWorkerClient.h"
6 #include "modules/serviceworkers/ServiceWorkerWindowClient.h" 6 #include "modules/serviceworkers/ServiceWorkerWindowClient.h"
7 7
8 #include "bindings/core/v8/CallbackPromiseAdapter.h" 8 #include "bindings/core/v8/CallbackPromiseAdapter.h"
9 #include "bindings/core/v8/ExceptionState.h" 9 #include "bindings/core/v8/ExceptionState.h"
10 #include "bindings/core/v8/SerializedScriptValue.h" 10 #include "bindings/core/v8/SerializedScriptValue.h"
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
71 { 71 {
72 // Disentangle the port in preparation for sending it to the remote context. 72 // Disentangle the port in preparation for sending it to the remote context.
73 OwnPtr<MessagePortChannelArray> channels = MessagePort::disentanglePorts(con text, ports, exceptionState); 73 OwnPtr<MessagePortChannelArray> channels = MessagePort::disentanglePorts(con text, ports, exceptionState);
74 if (exceptionState.hadException()) 74 if (exceptionState.hadException())
75 return; 75 return;
76 76
77 if (message->containsTransferableArrayBuffer()) 77 if (message->containsTransferableArrayBuffer())
78 context->addConsoleMessage(ConsoleMessage::create(JSMessageSource, Warni ngMessageLevel, "ServiceWorkerClient cannot send an ArrayBuffer as a transferabl e object yet. See http://crbug.com/511119")); 78 context->addConsoleMessage(ConsoleMessage::create(JSMessageSource, Warni ngMessageLevel, "ServiceWorkerClient cannot send an ArrayBuffer as a transferabl e object yet. See http://crbug.com/511119"));
79 79
80 WebString messageString = message->toWireString(); 80 WebString messageString = message->toWireString();
81 OwnPtr<WebMessagePortChannelArray> webChannels = MessagePort::toWebMessagePo rtChannelArray(channels.release()); 81 OwnPtr<WebMessagePortChannelArray> webChannels = MessagePort::toWebMessagePo rtChannelArray(std::move(channels));
82 ServiceWorkerGlobalScopeClient::from(context)->postMessageToClient(m_uuid, m essageString, webChannels.release()); 82 ServiceWorkerGlobalScopeClient::from(context)->postMessageToClient(m_uuid, m essageString, std::move(webChannels));
83 } 83 }
84 84
85 } // namespace blink 85 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698