diff options
author | evan@chromium.org <evan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-10-12 22:50:39 +0000 |
---|---|---|
committer | evan@chromium.org <evan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-10-12 22:50:39 +0000 |
commit | 0189bbd4cc569eaec4c6664109659c32fed8e4b7 (patch) | |
tree | f792f823d15a1e806d1b25d0f6d318622db6daf4 /chrome/browser/process_singleton_linux.cc | |
parent | 079487b08bf7867eb7c078b59dec61f142a42df2 (diff) | |
download | chromium_src-0189bbd4cc569eaec4c6664109659c32fed8e4b7.zip chromium_src-0189bbd4cc569eaec4c6664109659c32fed8e4b7.tar.gz chromium_src-0189bbd4cc569eaec4c6664109659c32fed8e4b7.tar.bz2 |
CommandLine: rejigger how initialization works.
I'm attempting to clean up CommandLine.
This change rearranges how initialization is done. I am trying
to eliminate redundant functions; more will come in subsequent changes.
Review URL: http://codereview.chromium.org/273018
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@28752 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/process_singleton_linux.cc')
-rw-r--r-- | chrome/browser/process_singleton_linux.cc | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/chrome/browser/process_singleton_linux.cc b/chrome/browser/process_singleton_linux.cc index 634b68f..bfff289 100644 --- a/chrome/browser/process_singleton_linux.cc +++ b/chrome/browser/process_singleton_linux.cc @@ -627,10 +627,12 @@ ProcessSingleton::~ProcessSingleton() { } ProcessSingleton::NotifyResult ProcessSingleton::NotifyOtherProcess() { - return NotifyOtherProcessWithTimeout(kTimeoutInSeconds); + return NotifyOtherProcessWithTimeout(*CommandLine::ForCurrentProcess(), + kTimeoutInSeconds); } ProcessSingleton::NotifyResult ProcessSingleton::NotifyOtherProcessWithTimeout( + const CommandLine& cmd_line, int timeout_seconds) { int socket; sockaddr_un addr; @@ -666,8 +668,7 @@ ProcessSingleton::NotifyResult ProcessSingleton::NotifyOtherProcessWithTimeout( return PROCESS_NONE; to_send.append(current_dir.value()); - const std::vector<std::string>& argv = - CommandLine::ForCurrentProcess()->argv(); + const std::vector<std::string>& argv = cmd_line.argv(); for (std::vector<std::string>::const_iterator it = argv.begin(); it != argv.end(); ++it) { to_send.push_back(kTokenDelimiter); |