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

Unified Diff: base/trace_event/trace_config.cc

Issue 2624583002: Remove redundant c_str() calls. (Closed)
Patch Set: Replace host() with host_piece() call Created 3 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 side-by-side diff with in-line comments
Download patch
Index: base/trace_event/trace_config.cc
diff --git a/base/trace_event/trace_config.cc b/base/trace_event/trace_config.cc
index 36de107bf8bc444426de0f16651306fb2a8d0b46..4f28d378fca4bb65cedc335ca70993d2757a8c1b 100644
--- a/base/trace_event/trace_config.cc
+++ b/base/trace_event/trace_config.cc
@@ -321,7 +321,7 @@ bool TraceConfig::IsCategoryGroupEnabled(
DCHECK(!TraceConfig::IsEmptyOrContainsLeadingOrTrailingWhitespace(
category_group_token))
<< "Disallowed category string";
- if (IsCategoryEnabled(category_group_token.c_str()))
+ if (IsCategoryEnabled(category_group_token))
return true;
if (!MatchPattern(category_group_token, TRACE_DISABLED_BY_DEFAULT("*")))
@@ -855,7 +855,7 @@ void TraceConfig::WriteCategoryFilterString(const StringList& delays,
}
}
-bool TraceConfig::IsCategoryEnabled(const char* category_name) const {
+bool TraceConfig::IsCategoryEnabled(StringPiece category_name) const {
// Check the disabled- filters and the disabled-* wildcard first so that a
// "*" filter does not include the disabled.
for (const std::string& category : disabled_categories_) {
« no previous file with comments | « base/trace_event/trace_config.h ('k') | chrome/browser/android/contextualsearch/contextual_search_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698