asyncwrap: add missing TryCatch

The TryCatch was not being checked after calling the unload asyncQueue
callback in AsyncWrap::MakeCallback.
pull/5010/head
Trevor Norris 2013-11-19 16:03:11 -08:00
parent 3ac6946999
commit aef652dc11
1 changed files with 3 additions and 0 deletions

View File

@ -117,6 +117,9 @@ inline v8::Handle<v8::Value> AsyncWrap::MakeCallback(
if (has_async_queue()) { if (has_async_queue()) {
v8::Local<v8::Value> val = context.As<v8::Value>(); v8::Local<v8::Value> val = context.As<v8::Value>();
env()->async_listener_unload_function()->Call(process, 1, &val); env()->async_listener_unload_function()->Call(process, 1, &val);
if (try_catch.HasCaught())
return v8::Undefined(env()->isolate());
} }
Environment::TickInfo* tick_info = env()->tick_info(); Environment::TickInfo* tick_info = env()->tick_info();