aboutsummaryrefslogtreecommitdiff
path: root/src/node_zlib.cc
diff options
context:
space:
mode:
authorBen Noordhuis <info@bnoordhuis.nl>2013-11-11 10:53:00 +0100
committerBen Noordhuis <info@bnoordhuis.nl>2013-11-12 22:06:48 +0100
commit27f115d715478b9a800927498ba606d4a62f927c (patch)
tree2a1c5b790d852f48f5547a72fa4e90ea146e004d /src/node_zlib.cc
parentc0d62c207ee67492619bde4af46502b5a3ce6a66 (diff)
downloadandroid-node-v8-27f115d715478b9a800927498ba606d4a62f927c.tar.gz
android-node-v8-27f115d715478b9a800927498ba606d4a62f927c.tar.bz2
android-node-v8-27f115d715478b9a800927498ba606d4a62f927c.zip
src: fix Context::Scope usage
env->context() may or may not create a new Local. It currently does not but don't depend on that behavior, create a HandleScope first.
Diffstat (limited to 'src/node_zlib.cc')
-rw-r--r--src/node_zlib.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/node_zlib.cc b/src/node_zlib.cc
index 43bec55a4f..c4da32e266 100644
--- a/src/node_zlib.cc
+++ b/src/node_zlib.cc
@@ -255,8 +255,8 @@ class ZCtx : public WeakObject {
ZCtx* ctx = CONTAINER_OF(work_req, ZCtx, work_req_);
Environment* env = ctx->env();
- Context::Scope context_scope(env->context());
HandleScope handle_scope(env->isolate());
+ Context::Scope context_scope(env->context());
// Acceptable error states depend on the type of zlib stream.
switch (ctx->err_) {