| Index: third_party/WebKit/Source/core/dom/MessagePort.cpp
|
| diff --git a/third_party/WebKit/Source/core/dom/MessagePort.cpp b/third_party/WebKit/Source/core/dom/MessagePort.cpp
|
| index 155592f3286587353d75ab2823731857359c1944..94fb61b9e220874153fac78f8ead1f3659f41885 100644
|
| --- a/third_party/WebKit/Source/core/dom/MessagePort.cpp
|
| +++ b/third_party/WebKit/Source/core/dom/MessagePort.cpp
|
| @@ -55,7 +55,6 @@ MessagePort::MessagePort(ExecutionContext& executionContext)
|
| , ActiveDOMObject(&executionContext)
|
| , m_started(false)
|
| , m_closed(false)
|
| - , m_weakFactory(this)
|
| {
|
| }
|
|
|
| @@ -73,7 +72,6 @@ void MessagePort::postMessage(ExecutionContext* context, PassRefPtr<SerializedSc
|
| DCHECK(getExecutionContext());
|
| DCHECK(m_entangledChannel);
|
|
|
| - OwnPtr<MessagePortChannelArray> channels;
|
| // Make sure we aren't connected to any of the passed-in ports.
|
| for (unsigned i = 0; i < ports.size(); ++i) {
|
| if (ports[i] == this) {
|
| @@ -81,7 +79,7 @@ void MessagePort::postMessage(ExecutionContext* context, PassRefPtr<SerializedSc
|
| return;
|
| }
|
| }
|
| - channels = MessagePort::disentanglePorts(context, ports, exceptionState);
|
| + OwnPtr<MessagePortChannelArray> channels = MessagePort::disentanglePorts(context, ports, exceptionState);
|
| if (exceptionState.hadException())
|
| return;
|
|
|
| @@ -126,7 +124,7 @@ PassOwnPtr<WebMessagePortChannel> MessagePort::disentangle()
|
| void MessagePort::messageAvailable()
|
| {
|
| DCHECK(getExecutionContext());
|
| - getExecutionContext()->postTask(BLINK_FROM_HERE, createCrossThreadTask(&MessagePort::dispatchMessages, m_weakFactory.createWeakPtr()));
|
| + getExecutionContext()->postTask(BLINK_FROM_HERE, createCrossThreadTask(&MessagePort::dispatchMessages, CrossThreadWeakPersistentThisPointer<MessagePort>(this)));
|
| }
|
|
|
| void MessagePort::start()
|
|
|