diff options
author | Ben Noordhuis <info@bnoordhuis.nl> | 2013-11-11 10:53:00 +0100 |
---|---|---|
committer | Ben Noordhuis <info@bnoordhuis.nl> | 2013-11-12 22:06:48 +0100 |
commit | 27f115d715478b9a800927498ba606d4a62f927c (patch) | |
tree | 2a1c5b790d852f48f5547a72fa4e90ea146e004d /src/signal_wrap.cc | |
parent | c0d62c207ee67492619bde4af46502b5a3ce6a66 (diff) | |
download | android-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/signal_wrap.cc')
-rw-r--r-- | src/signal_wrap.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/signal_wrap.cc b/src/signal_wrap.cc index 1eade0bd96..821b6dc580 100644 --- a/src/signal_wrap.cc +++ b/src/signal_wrap.cc @@ -100,8 +100,8 @@ class SignalWrap : public HandleWrap { static void OnSignal(uv_signal_t* handle, int signum) { SignalWrap* wrap = CONTAINER_OF(handle, SignalWrap, handle_); Environment* env = wrap->env(); - Context::Scope context_scope(env->context()); HandleScope handle_scope(env->isolate()); + Context::Scope context_scope(env->context()); Local<Value> arg = Integer::New(signum, env->isolate()); wrap->MakeCallback(env->onsignal_string(), 1, &arg); |