aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorGravatar murgatroid99 <mlumish@google.com>2015-09-14 14:16:04 -0700
committerGravatar murgatroid99 <mlumish@google.com>2015-09-14 16:45:31 -0700
commit640325e65eb52c213be8349b7f4400cf4cc7f62e (patch)
treeea97437d546e890612fea19c5528eda36659ab5f
parent474f53b13835b5f42e0ef86947497eba28b45441 (diff)
Fixed memory leak in Buffer construction
-rw-r--r--src/node/ext/byte_buffer.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/node/ext/byte_buffer.cc b/src/node/ext/byte_buffer.cc
index 7eff11c2b3..fe7735d429 100644
--- a/src/node/ext/byte_buffer.cc
+++ b/src/node/ext/byte_buffer.cc
@@ -77,7 +77,7 @@ Handle<Value> ByteBufferToBuffer(grpc_byte_buffer *buffer) {
memcpy(result + offset, GPR_SLICE_START_PTR(next), GPR_SLICE_LENGTH(next));
offset += GPR_SLICE_LENGTH(next);
}
- return NanEscapeScope(MakeFastBuffer(NanNewBufferHandle(result, length)));
+ return NanEscapeScope(MakeFastBuffer(NanBufferUse(result, length)));
}
Handle<Value> MakeFastBuffer(Handle<Value> slowBuffer) {