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

Unified Diff: mojo/shell/context.cc

Issue 599733007: Allow passing listening socket path on command line (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 3 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/shell/context.cc
diff --git a/mojo/shell/context.cc b/mojo/shell/context.cc
index 253f4b7d24d85bf6b2fc2498b2151b2ef238a697..6aa84f809d2d006bf9fa62f1d567ffd260558640 100644
--- a/mojo/shell/context.cc
+++ b/mojo/shell/context.cc
@@ -185,8 +185,14 @@ void Context::Init() {
if (command_line->HasSwitch(switches::kEnableExternalApplications)) {
listener_ = ExternalApplicationListener::Create(
task_runners_->shell_runner(), task_runners_->io_runner());
+
+ base::FilePath socket_path =
+ command_line->GetSwitchValuePath(switches::kEnableExternalApplications);
+ if (socket_path.empty())
+ socket_path = ExternalApplicationListener::ConstructDefaultSocketPath();
+
listener_->ListenInBackground(
- ExternalApplicationListener::ConstructDefaultSocketPath(),
+ socket_path,
base::Bind(&ApplicationManager::RegisterExternalApplication,
base::Unretained(&application_manager_)));
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698