diff options
author | tim@chromium.org <tim@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-04-30 17:00:24 +0000 |
---|---|---|
committer | tim@chromium.org <tim@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-04-30 17:00:24 +0000 |
commit | 7f74a4ee8538089c11895ff2f3b7110f3ca0061b (patch) | |
tree | cd49fd9715d351cb282b9b348ddca2da540133b8 /chrome/browser | |
parent | 06f666707b420f11a454929e4de0fbb843d71d55 (diff) | |
download | chromium_src-7f74a4ee8538089c11895ff2f3b7110f3ca0061b.zip chromium_src-7f74a4ee8538089c11895ff2f3b7110f3ca0061b.tar.gz chromium_src-7f74a4ee8538089c11895ff2f3b7110f3ca0061b.tar.bz2 |
Fix issue 11006 - any plugin process started by InProcessBrowserTest was
using the unit_test executable rather than chrome.exe. This patch repurposes
the --renderer-path switch to be --browser-subprocess-path for both plugins and
renderers.
BUG=11006
TEST=Any InProcessBrowserTest (they all will start at least one renderer). Use
NavigateToURL to a URL containing flash, we shouldn't crash.
Review URL: http://codereview.chromium.org/99011
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@14951 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser')
-rw-r--r-- | chrome/browser/plugin_process_host.cc | 8 | ||||
-rw-r--r-- | chrome/browser/renderer_host/browser_render_process_host.cc | 2 |
2 files changed, 5 insertions, 5 deletions
diff --git a/chrome/browser/plugin_process_host.cc b/chrome/browser/plugin_process_host.cc index 4d50664..51306f3 100644 --- a/chrome/browser/plugin_process_host.cc +++ b/chrome/browser/plugin_process_host.cc @@ -318,16 +318,16 @@ bool PluginProcessHost::Init(const WebPluginInfo& info, // build command line for plugin, we have to quote the plugin's path to deal // with spaces. - std::wstring exe_path; - if (!PathService::Get(base::FILE_EXE, &exe_path)) + const CommandLine& browser_command_line = *CommandLine::ForCurrentProcess(); + std::wstring exe_path = + browser_command_line.GetSwitchValue(switches::kBrowserSubprocessPath); + if (exe_path.empty() && !PathService::Get(base::FILE_EXE, &exe_path)) return false; CommandLine cmd_line(exe_path); if (logging::DialogsAreSuppressed()) cmd_line.AppendSwitch(switches::kNoErrorDialogs); - const CommandLine& browser_command_line = *CommandLine::ForCurrentProcess(); - // propagate the following switches to the plugin command line (along with // any associated values) if present in the browser command line static const wchar_t* const switch_names[] = { diff --git a/chrome/browser/renderer_host/browser_render_process_host.cc b/chrome/browser/renderer_host/browser_render_process_host.cc index 885a086..af67872 100644 --- a/chrome/browser/renderer_host/browser_render_process_host.cc +++ b/chrome/browser/renderer_host/browser_render_process_host.cc @@ -220,7 +220,7 @@ bool BrowserRenderProcessHost::Init() { // Build command line for renderer, we have to quote the executable name to // deal with spaces. std::wstring renderer_path = - browser_command_line.GetSwitchValue(switches::kRendererPath); + browser_command_line.GetSwitchValue(switches::kBrowserSubprocessPath); if (renderer_path.empty()) { if (!GetRendererPath(&renderer_path)) { // Need to reset the channel we created above or others might think the |