diff options
author | maruel@chromium.org <maruel@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-05-21 17:14:57 +0000 |
---|---|---|
committer | maruel@chromium.org <maruel@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-05-21 17:14:57 +0000 |
commit | d3b04abc5ce706d8950c2f6beb2aa438f1edcd5a (patch) | |
tree | 9dd143da4fcabc7f407a247c69cba11960ed930b /base | |
parent | e7c674264be7bbbffae48e29333f40c0b46cb874 (diff) | |
download | chromium_src-d3b04abc5ce706d8950c2f6beb2aa438f1edcd5a.zip chromium_src-d3b04abc5ce706d8950c2f6beb2aa438f1edcd5a.tar.gz chromium_src-d3b04abc5ce706d8950c2f6beb2aa438f1edcd5a.tar.bz2 |
Fixed a TODO in data export of net-internals, added Chrome version and command line.
BUG=none
TEST=Go to about:net-internals click on dump to text, check if version and command line are good.
Patch contributed by malavv
Review URL: http://codereview.chromium.org/2104012
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@47926 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base')
-rw-r--r-- | base/command_line.cc | 5 | ||||
-rw-r--r-- | base/command_line.h | 3 |
2 files changed, 8 insertions, 0 deletions
diff --git a/base/command_line.cc b/base/command_line.cc index bc4e1a0..2c6ef0b 100644 --- a/base/command_line.cc +++ b/base/command_line.cc @@ -303,6 +303,11 @@ std::wstring CommandLine::program() const { } #endif +#if defined(OS_POSIX) +std::string CommandLine::command_line_string() const { + return JoinString(argv_, ' '); +} +#endif // static std::wstring CommandLine::PrefixedSwitchString( diff --git a/base/command_line.h b/base/command_line.h index 864cb56..b6b1028 100644 --- a/base/command_line.h +++ b/base/command_line.h @@ -148,6 +148,9 @@ class CommandLine { const std::vector<std::string>& argv() const { return argv_; } + // Try to match the same result as command_line_string() would get you + // on windows. + std::string command_line_string() const; #endif // Returns the program part of the command line string (the first item). |