Skip to content

Commit

Permalink
src: null env_ field from constructor
Browse files Browse the repository at this point in the history
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: #2913
Reviewed-By: Fedor Indutny <fedor@indutny.com>
  • Loading branch information
trevnorris committed Sep 16, 2015
1 parent 6cb9e8a commit 3b78b85
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/node_internals.h
Original file line number Diff line number Diff line change
Expand Up @@ -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; }

Expand Down

0 comments on commit 3b78b85

Please sign in to comment.