Skip to content

Commit

Permalink
src: fix deprecated use of Buffer::New()
Browse files Browse the repository at this point in the history
Pass the isolate explicitly.  Overlooked in commit ccb199a ("src: fix
deprecation warnings") because g++ 4.8 and 4.9 don't warn for it
whereas g++ 5.1 does.
  • Loading branch information
bnoordhuis committed May 1, 2015
1 parent 30b7349 commit bb3ed4d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/string_bytes.cc
Original file line number Diff line number Diff line change
Expand Up @@ -681,7 +681,7 @@ Local<Value> StringBytes::Encode(Isolate* isolate,
Local<String> val;
switch (encoding) {
case BUFFER:
return scope.Escape(Buffer::New(buf, buflen));
return scope.Escape(Buffer::New(isolate, buf, buflen));

case ASCII:
if (contains_non_ascii(buf, buflen)) {
Expand Down

0 comments on commit bb3ed4d

Please sign in to comment.