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

Unified Diff: apps/benchmark/run_args.cc

Issue 1915443002: Enable the use of spaces within a benchmark measurement name (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | mojo/devtools/common/devtoolslib/benchmark.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: apps/benchmark/run_args.cc
diff --git a/apps/benchmark/run_args.cc b/apps/benchmark/run_args.cc
index fdb36645e94887d75226273d8fa6188afe949e51..6f4adbaf95b9a6c403c26079157d38b84ecd530e 100644
--- a/apps/benchmark/run_args.cc
+++ b/apps/benchmark/run_args.cc
@@ -10,6 +10,7 @@
#include "base/logging.h"
#include "base/strings/string_number_conversions.h"
#include "base/strings/string_split.h"
+#include "base/strings/string_util.h"
namespace benchmark {
namespace {
@@ -115,7 +116,9 @@ bool GetRunArgs(const std::vector<std::string>& input_args, RunArgs* result) {
// measurements.
for (const std::string& measurement_spec : command_line.GetArgs()) {
Measurement measurement;
- if (!GetMeasurement(measurement_spec, &measurement)) {
+ std::string unquoted_measurement_spec;
+ base::TrimString(measurement_spec, "'\"", &unquoted_measurement_spec);
+ if (!GetMeasurement(unquoted_measurement_spec, &measurement)) {
return false;
}
result->measurements.push_back(measurement);
« no previous file with comments | « no previous file | mojo/devtools/common/devtoolslib/benchmark.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698