Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(394)

Side by Side Diff: src/debug.cc

Issue 113900: Don't process debug requests if the debug event is script collected (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 11 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2006-2008 the V8 project authors. All rights reserved. 1 // Copyright 2006-2008 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 2016 matching lines...) Expand 10 before | Expand all | Expand 10 after
2027 // Notify the debugger that a debug event has occurred unless auto continue is 2027 // Notify the debugger that a debug event has occurred unless auto continue is
2028 // active in which case no event is send. 2028 // active in which case no event is send.
2029 if (sendEventMessage) { 2029 if (sendEventMessage) {
2030 MessageImpl message = MessageImpl::NewEvent( 2030 MessageImpl message = MessageImpl::NewEvent(
2031 event, 2031 event,
2032 auto_continue, 2032 auto_continue,
2033 Handle<JSObject>::cast(exec_state), 2033 Handle<JSObject>::cast(exec_state),
2034 Handle<JSObject>::cast(event_data)); 2034 Handle<JSObject>::cast(event_data));
2035 InvokeMessageHandler(message); 2035 InvokeMessageHandler(message);
2036 } 2036 }
2037 if (auto_continue && !HasCommands()) { 2037
2038 // If auto continue don't make the event cause a break, but process messages
2039 // in the queue if any. For script collected events don't even process
2040 // messages in the queue as the execution state might not be what is expected
2041 // by the client.
2042 if (auto_continue && !HasCommands() || event == v8::ScriptCollected) {
2038 return; 2043 return;
2039 } 2044 }
2040 2045
2041 // Get the DebugCommandProcessor. 2046 // Get the DebugCommandProcessor.
2042 v8::Local<v8::Object> api_exec_state = 2047 v8::Local<v8::Object> api_exec_state =
2043 v8::Utils::ToLocal(Handle<JSObject>::cast(exec_state)); 2048 v8::Utils::ToLocal(Handle<JSObject>::cast(exec_state));
2044 v8::Local<v8::String> fun_name = 2049 v8::Local<v8::String> fun_name =
2045 v8::String::New("debugCommandProcessor"); 2050 v8::String::New("debugCommandProcessor");
2046 v8::Local<v8::Function> fun = 2051 v8::Local<v8::Function> fun =
2047 v8::Function::Cast(*api_exec_state->Get(fun_name)); 2052 v8::Function::Cast(*api_exec_state->Get(fun_name));
(...skipping 476 matching lines...) Expand 10 before | Expand all | Expand 10 after
2524 2529
2525 2530
2526 void LockingCommandMessageQueue::Clear() { 2531 void LockingCommandMessageQueue::Clear() {
2527 ScopedLock sl(lock_); 2532 ScopedLock sl(lock_);
2528 queue_.Clear(); 2533 queue_.Clear();
2529 } 2534 }
2530 2535
2531 #endif // ENABLE_DEBUGGER_SUPPORT 2536 #endif // ENABLE_DEBUGGER_SUPPORT
2532 2537
2533 } } // namespace v8::internal 2538 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698