diff options
author | Fedor Indutny <fedor.indutny@gmail.com> | 2012-01-06 22:26:53 +0400 |
---|---|---|
committer | Ben Noordhuis <info@bnoordhuis.nl> | 2012-01-10 05:19:14 +0400 |
commit | 44e703327970be080877ad7c02f57f0713b553b8 (patch) | |
tree | 16ff20ee4a4d4b2a537e20f2eb154de69433b59e /src | |
parent | a5f74b4da7ad3f4946cb5e0db7c94ee6bf8e5718 (diff) |
fixed debugger segfaults
Diffstat (limited to 'src')
-rw-r--r-- | src/node.cc | 28 | ||||
-rw-r--r-- | src/node_vars.h | 1 |
2 files changed, 0 insertions, 29 deletions
diff --git a/src/node.cc b/src/node.cc index 45eb0782183..c6efa89f2bf 100644 --- a/src/node.cc +++ b/src/node.cc @@ -122,7 +122,6 @@ extern char **environ; #define use_npn NODE_VAR(use_npn) #define use_sni NODE_VAR(use_sni) #define uncaught_exception_counter NODE_VAR(uncaught_exception_counter) -#define debug_watcher NODE_VAR(debug_watcher) #define binding_cache NODE_VAR(binding_cache) #define module_load_list NODE_VAR(module_load_list) #define node_isolate NODE_VAR(node_isolate) @@ -1783,21 +1782,6 @@ void FatalException(TryCatch &try_catch) { } -static void DebugMessageCallback(uv_async_t* watcher, int status) { - HandleScope scope; - assert(watcher == &debug_watcher); - v8::Debug::ProcessDebugMessages(); -} - -static void DebugMessageDispatch(void) { - // This function is called from V8's debug thread when a debug TCP client - // has sent a message. - - // Send a signal to our main thread saying that it should enter V8 to - // handle the message. - uv_async_send(&debug_watcher); -} - static void DebugBreakMessageHandler(const v8::Debug::Message& message) { // do nothing with debug messages. // The message handler will get changed by DebuggerAgent::CreateSession in @@ -2636,18 +2620,6 @@ void StartThread(node::Isolate* isolate, V8::SetFatalErrorHandler(node::OnFatalError); - // Set the callback DebugMessageDispatch which is called from the debug - // thread. - v8::Debug::SetDebugMessageDispatchHandler(node::DebugMessageDispatch); - - // Initialize the async watcher. DebugMessageCallback() is called from the - // main thread to execute a random bit of javascript - which will give V8 - // control so it can handle whatever new message had been received on the - // debug thread. - uv_async_init(loop, &debug_watcher, node::DebugMessageCallback); - // unref it so that we exit the event loop despite it being active. - uv_unref(loop); - // Fetch a reference to the main isolate, so we have a reference to it // even when we need it to access it from another (debugger) thread. node_isolate = v8::Isolate::GetCurrent(); diff --git a/src/node_vars.h b/src/node_vars.h index acf581eafba..4ec628497c2 100644 --- a/src/node_vars.h +++ b/src/node_vars.h @@ -58,7 +58,6 @@ struct globals { int64_t tick_times[RPM_SAMPLES]; int tick_time_head; int uncaught_exception_counter; - uv_async_t debug_watcher; v8::Persistent<v8::Object> binding_cache; v8::Persistent<v8::Array> module_load_list; v8::Isolate* node_isolate; |