base: Support command line wrappers with quoted arguments
Command line wrappers (e.g., --renderer-cmd-prefix) were previously
split into individual arguments purely based on whitespace. This fails
if the prefix has arguments with embedded whitespace (e.g., gdb -ex "set
height 0").
This patch fixes the issue by tokenizing the prefix based on whitespace
while using ' and " as quote characters.
BUG=546953
Review-Url: https://codereview.chromium.org/2778173003
Cr-Commit-Position: refs/heads/master@{#460443}
CrOS-Libchrome-Original-Commit: d851aa1e5290a777a7a82afdbe6c27df2cf82bf2
2 files changed