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

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

Issue 14320028: Restore skipping of default categories. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 8 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 | base/debug/trace_event_unittest.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) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/trace_event_impl.h" 5 #include "base/debug/trace_event_impl.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/debug/leak_annotations.h" 10 #include "base/debug/leak_annotations.h"
(...skipping 845 matching lines...) Expand 10 before | Expand all | Expand 10 after
856 } 856 }
857 #if defined(OS_ANDROID) 857 #if defined(OS_ANDROID)
858 ApplyATraceEnabledFlag(category_group_enabled); 858 ApplyATraceEnabledFlag(category_group_enabled);
859 #endif 859 #endif
860 return category_group_enabled; 860 return category_group_enabled;
861 } 861 }
862 862
863 void TraceLog::GetKnownCategoryGroups( 863 void TraceLog::GetKnownCategoryGroups(
864 std::vector<std::string>* category_groups) { 864 std::vector<std::string>* category_groups) {
865 AutoLock lock(lock_); 865 AutoLock lock(lock_);
866 for (int i = 0; i < g_category_index; i++) 866 for (int i = g_num_builtin_categories; i < g_category_index; i++)
867 category_groups->push_back(g_category_groups[i]); 867 category_groups->push_back(g_category_groups[i]);
868 } 868 }
869 869
870 void TraceLog::SetEnabled(const CategoryFilter& category_filter, 870 void TraceLog::SetEnabled(const CategoryFilter& category_filter,
871 Options options) { 871 Options options) {
872 AutoLock lock(lock_); 872 AutoLock lock(lock_);
873 873
874 if (enable_count_++ > 0) { 874 if (enable_count_++ > 0) {
875 if (options != trace_options_) { 875 if (options != trace_options_) {
876 DLOG(ERROR) << "Attemting to re-enable tracing with a different " 876 DLOG(ERROR) << "Attemting to re-enable tracing with a different "
(...skipping 544 matching lines...) Expand 10 before | Expand all | Expand 10 after
1421 NULL, // arg_names 1421 NULL, // arg_names
1422 NULL, // arg_types 1422 NULL, // arg_types
1423 NULL, // arg_values 1423 NULL, // arg_values
1424 NULL, // convertable values 1424 NULL, // convertable values
1425 TRACE_EVENT_FLAG_NONE); // flags 1425 TRACE_EVENT_FLAG_NONE); // flags
1426 } 1426 }
1427 } 1427 }
1428 1428
1429 } // namespace trace_event_internal 1429 } // namespace trace_event_internal
1430 1430
OLDNEW
« no previous file with comments | « no previous file | base/debug/trace_event_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698