Fix leak of ModuleInformations in BBQPlan constructors.
authorkeith_miller@apple.com <keith_miller@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 21 Jun 2017 00:32:25 +0000 (00:32 +0000)
committerkeith_miller@apple.com <keith_miller@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 21 Jun 2017 00:32:25 +0000 (00:32 +0000)
commitdeb301a07692b236538c125b33e13cc958173b45
tree3ffbfc4dd288b680a25017af3d776bdeeac70784
parentbbb0543d0ee4392eb6634d89365f01b7fbc4520e
Fix leak of ModuleInformations in BBQPlan constructors.
https://bugs.webkit.org/show_bug.cgi?id=173577

Reviewed by Saam Barati.

This patch fixes a leak in the BBQPlan constructiors. Previously,
the plans were calling makeRef on the newly constructed objects.
This patch fixes the issue and uses adoptRef instead. Additionally,
an old, incorrect, attempt to fix the leak is removed.

* inspector/remote/cocoa/RemoteInspectorXPCConnection.mm:
(Inspector::RemoteInspectorXPCConnection::RemoteInspectorXPCConnection):
* jit/JITWorklist.cpp:
(JSC::JITWorklist::Thread::Thread):
* runtime/PromiseDeferredTimer.cpp:
(JSC::PromiseDeferredTimer::addPendingPromise):
* runtime/VM.cpp:
(JSC::VM::VM):
* wasm/WasmBBQPlan.cpp:
(JSC::Wasm::BBQPlan::BBQPlan):
* wasm/WasmPlan.cpp:
(JSC::Wasm::Plan::Plan):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@218619 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/JavaScriptCore/ChangeLog
Source/JavaScriptCore/runtime/PromiseDeferredTimer.cpp
Source/JavaScriptCore/wasm/WasmBBQPlan.cpp
Source/JavaScriptCore/wasm/WasmPlan.cpp