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

Unified Diff: examples/native_run_app/native_run_app.cc

Issue 2022983003: Roll base to 5e00da80f6adb7082d1c0e88d3274cf87cc43bc5 and tonic to f7acabb8fa6c91124486a41194eac3cd… (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 4 years, 7 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: examples/native_run_app/native_run_app.cc
diff --git a/examples/native_run_app/native_run_app.cc b/examples/native_run_app/native_run_app.cc
index 090ba7eb0a5cf01f6d69e8d00318fd70a16920c3..dc02ff039a59395f1703740ab6dea02388c540db 100644
--- a/examples/native_run_app/native_run_app.cc
+++ b/examples/native_run_app/native_run_app.cc
@@ -22,6 +22,7 @@
#include "base/logging.h"
#include "base/macros.h"
#include "base/strings/string_split.h"
+#include "base/strings/string_util.h"
#include "mojo/public/c/system/main.h"
#include "mojo/public/cpp/application/application_delegate.h"
#include "mojo/public/cpp/application/application_impl_base.h"
@@ -95,8 +96,10 @@ class TerminalConnection {
std::string input(reinterpret_cast<const char*>(&bytes_read[0]),
bytes_read.size());
- command_line_.clear();
- base::SplitStringAlongWhitespace(input, &command_line_);
+ // TODO(vtl): Are these arguments really what we want? Probably not.
+ command_line_ =
+ base::SplitString(input, base::kWhitespaceASCII, base::KEEP_WHITESPACE,
+ base::SPLIT_WANT_NONEMPTY);
if (command_line_.empty()) {
Start();
« no previous file with comments | « examples/device_name/java/src/org/chromium/mojo/examples/DeviceName.java ('k') | examples/ui/tile/tile_app.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698