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

Side by Side Diff: base/debug/debugger.cc

Issue 6001010: Move platform_thread to base/threading and put in the base namespace. I left ... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 9 years, 11 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 | « base/condition_variable_unittest.cc ('k') | base/debug/trace_event.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "base/debug/debugger.h" 5 #include "base/debug/debugger.h"
6 6
7 #include "base/platform_thread.h" 7 #include "base/threading/platform_thread.h"
8 8
9 namespace base { 9 namespace base {
10 namespace debug { 10 namespace debug {
11 11
12 bool WaitForDebugger(int wait_seconds, bool silent) { 12 bool WaitForDebugger(int wait_seconds, bool silent) {
13 for (int i = 0; i < wait_seconds * 10; ++i) { 13 for (int i = 0; i < wait_seconds * 10; ++i) {
14 if (BeingDebugged()) { 14 if (BeingDebugged()) {
15 if (!silent) 15 if (!silent)
16 BreakDebugger(); 16 BreakDebugger();
17 return true; 17 return true;
18 } 18 }
19 PlatformThread::Sleep(100); 19 PlatformThread::Sleep(100);
20 } 20 }
21 return false; 21 return false;
22 } 22 }
23 23
24 } // namespace debug 24 } // namespace debug
25 } // namespace base 25 } // namespace base
OLDNEW
« no previous file with comments | « base/condition_variable_unittest.cc ('k') | base/debug/trace_event.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698