From: Trevor Norris Date: Wed, 16 Sep 2015 18:00:50 +0000 (-0600) Subject: src: null env_ field from constructor X-Git-Tag: v4.1.0~6 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=8e5843405b2d5ca394d0cba2544e56e72c25de71;p=platform%2Fupstream%2Fnodejs.git src: null env_ field from constructor The env_ field in ArrayBufferAllocator needs to be null'd out since it is used during initialization and checked prior to properly being set by set_env(). Fixes: 74178a5 "buffer: construct Uint8Array in JS" PR-URL: https://github.com/nodejs/node/pull/2913 Reviewed-By: Fedor Indutny --- diff --git a/src/node_internals.h b/src/node_internals.h index 5cc439c..bfe4fce 100644 --- a/src/node_internals.h +++ b/src/node_internals.h @@ -230,7 +230,7 @@ NODE_DEPRECATED("Use ThrowUVException(isolate)", class ArrayBufferAllocator : public v8::ArrayBuffer::Allocator { public: - ArrayBufferAllocator() { } + ArrayBufferAllocator() : env_(nullptr) { } inline void set_env(Environment* env) { env_ = env; }