From 6bebadddb399ad1c1f91592efed410040617e708 Mon Sep 17 00:00:00 2001 From: amistry Date: Mon, 21 Mar 2016 11:32:47 -0700 Subject: Add mach ports support to the Mojo shell. BUG=582468 Review URL: https://codereview.chromium.org/1812523003 Cr-Commit-Position: refs/heads/master@{#382335} --- mojo/shell/standalone/context.cc | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'mojo/shell/standalone') diff --git a/mojo/shell/standalone/context.cc b/mojo/shell/standalone/context.cc index 5b53879..e64ed82 100644 --- a/mojo/shell/standalone/context.cc +++ b/mojo/shell/standalone/context.cc @@ -43,6 +43,10 @@ #include "mojo/shell/switches.h" #include "mojo/util/filename_util.h" +#if defined(OS_MACOSX) +#include "mojo/shell/runner/host/mach_broker.h" +#endif + namespace mojo { namespace shell { namespace { @@ -136,8 +140,12 @@ void Context::Init(scoped_ptr init_params) { blocking_pool_ = new base::SequencedWorkerPool(kMaxBlockingPoolThreads, "blocking_pool"); - if (!init_params || init_params->init_edk) + if (!init_params || init_params->init_edk) { edk::InitIPCSupport(this, io_thread_->task_runner().get()); +#if defined(OS_MACOSX) + edk::SetMachPortProvider(MachBroker::GetInstance()->port_provider()); +#endif + } scoped_ptr runner_factory; if (command_line.HasSwitch(switches::kSingleProcess)) { -- cgit v1.1