Fix race in debugger threads in cctest/test-debug

BUG=none
R=svenpanne@chromium.org, ishell@chromium.org
LOG=n

Review URL: https://codereview.chromium.org/637283002

git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@24455 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
This commit is contained in:
jochen@chromium.org 2014-10-08 08:56:57 +00:00
parent bb5b39260b
commit c5c02d3bd4

View File

@ -5264,6 +5264,7 @@ void V8Thread::Run() {
CompileRun(source);
}
threaded_debugging_barriers.barrier_4.Wait();
isolate_->Dispose();
}
@ -5285,6 +5286,7 @@ void DebuggerThread::Run() {
threaded_debugging_barriers.barrier_2.Wait();
v8::Debug::SendCommand(isolate_, buffer, AsciiToUtf16(command_1, buffer));
v8::Debug::SendCommand(isolate_, buffer, AsciiToUtf16(command_2, buffer));
threaded_debugging_barriers.barrier_4.Wait();
}
@ -5388,6 +5390,7 @@ void BreakpointsV8Thread::Run() {
breakpoints_barriers->barrier_2.Wait();
CompileRun(source_2);
}
breakpoints_barriers->barrier_4.Wait();
isolate_->Dispose();
}
@ -5503,6 +5506,7 @@ void BreakpointsDebuggerThread::Run() {
CHECK_EQ(116, evaluate_int_result);
// 9: Continue evaluation of source2, reach end.
v8::Debug::SendCommand(isolate_, buffer, AsciiToUtf16(command_8, buffer));
breakpoints_barriers->barrier_4.Wait();
}