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

Side by Side Diff: content/browser/trace_message_filter.cc

Issue 9447003: Revert 123140 - Use SequencedWorkerPool for disk operations in TraceSubscriberStdio. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 10 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 | « content/browser/trace_controller.cc ('k') | content/browser/trace_subscriber_stdio.h » ('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) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 "content/browser/trace_message_filter.h" 5 #include "content/browser/trace_message_filter.h"
6 6
7 #include "content/browser/trace_controller.h" 7 #include "content/browser/trace_controller.h"
8 #include "content/common/child_process_messages.h" 8 #include "content/common/child_process_messages.h"
9 9
10 using content::BrowserMessageFilter; 10 using content::BrowserMessageFilter;
11 using content::BrowserThread; 11 using content::BrowserThread;
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after
89 const std::vector<std::string>& known_categories) { 89 const std::vector<std::string>& known_categories) {
90 // is_awaiting_end_ack_ should always be true here, but check in case the 90 // is_awaiting_end_ack_ should always be true here, but check in case the
91 // child process is compromised. 91 // child process is compromised.
92 if (is_awaiting_end_ack_) { 92 if (is_awaiting_end_ack_) {
93 is_awaiting_end_ack_ = false; 93 is_awaiting_end_ack_ = false;
94 TraceController::GetInstance()->OnEndTracingAck(known_categories); 94 TraceController::GetInstance()->OnEndTracingAck(known_categories);
95 } 95 }
96 } 96 }
97 97
98 void TraceMessageFilter::OnTraceDataCollected(const std::string& data) { 98 void TraceMessageFilter::OnTraceDataCollected(const std::string& data) {
99 scoped_refptr<base::RefCountedString> data_ptr(new base::RefCountedString()); 99 TraceController::GetInstance()->OnTraceDataCollected(
100 data_ptr->data() = data; 100 make_scoped_refptr(new base::debug::TraceLog::RefCountedString(data)));
101 TraceController::GetInstance()->OnTraceDataCollected(data_ptr);
102 } 101 }
103 102
104 void TraceMessageFilter::OnTraceBufferFull() { 103 void TraceMessageFilter::OnTraceBufferFull() {
105 TraceController::GetInstance()->OnTraceBufferFull(); 104 TraceController::GetInstance()->OnTraceBufferFull();
106 } 105 }
107 106
108 void TraceMessageFilter::OnTraceBufferPercentFullReply(float percent_full) { 107 void TraceMessageFilter::OnTraceBufferPercentFullReply(float percent_full) {
109 if (is_awaiting_bpf_ack_) { 108 if (is_awaiting_bpf_ack_) {
110 is_awaiting_bpf_ack_ = false; 109 is_awaiting_bpf_ack_ = false;
111 TraceController::GetInstance()->OnTraceBufferPercentFullReply( 110 TraceController::GetInstance()->OnTraceBufferPercentFullReply(
112 percent_full); 111 percent_full);
113 } 112 }
114 } 113 }
115 114
OLDNEW
« no previous file with comments | « content/browser/trace_controller.cc ('k') | content/browser/trace_subscriber_stdio.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698