From dc8b57fdc191dca0de4597b67f3f7d2a3def95d3 Mon Sep 17 00:00:00 2001 From: Anna Henningsen Date: Tue, 16 Apr 2019 11:26:45 +0200 Subject: [PATCH] src: use ArrayBufferAllocator::Create in node_worker.cc Refs: https://github.com/nodejs/node/pull/27220 PR-URL: https://github.com/nodejs/node/pull/27251 Reviewed-By: Ben Noordhuis Reviewed-By: Colin Ihrig Reviewed-By: Joyee Cheung Reviewed-By: James M Snell --- src/node_worker.cc | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/node_worker.cc b/src/node_worker.cc index b9143eca7aafdd..c1a1123ef1399e 100644 --- a/src/node_worker.cc +++ b/src/node_worker.cc @@ -117,7 +117,7 @@ class WorkerThreadData { public: explicit WorkerThreadData(Worker* w) : w_(w), - array_buffer_allocator_(CreateArrayBufferAllocator()) { + array_buffer_allocator_(ArrayBufferAllocator::Create()) { CHECK_EQ(uv_loop_init(&loop_), 0); Isolate* isolate = NewIsolate(array_buffer_allocator_.get(), &loop_); @@ -174,8 +174,7 @@ class WorkerThreadData { private: Worker* const w_; uv_loop_t loop_; - DeleteFnPtr - array_buffer_allocator_; + std::unique_ptr array_buffer_allocator_; DeleteFnPtr isolate_data_; friend class Worker;