| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "native_client/src/trusted/plugin/sel_ldr_launcher_chrome.h" | 5 #include "native_client/src/trusted/plugin/sel_ldr_launcher_chrome.h" |
| 6 | 6 |
| 7 #include "native_client/src/trusted/plugin/nacl_entry_points.h" | 7 #include "native_client/src/trusted/plugin/nacl_entry_points.h" |
| 8 | 8 |
| 9 LaunchNaClProcessFunc launch_nacl_process = NULL; | 9 LaunchNaClProcessFunc launch_nacl_process = NULL; |
| 10 | 10 |
| 11 namespace plugin { | 11 namespace plugin { |
| 12 | 12 |
| 13 bool SelLdrLauncherChrome::Start(const char* url) { | 13 bool SelLdrLauncherChrome::Start(const char* url) { |
| 14 return Start(0, url); | 14 return Start(0, url, NULL); |
| 15 } | 15 } |
| 16 | 16 |
| 17 bool SelLdrLauncherChrome::Start(PP_Instance instance, const char* url) { | 17 bool SelLdrLauncherChrome::Start(PP_Instance instance, |
| 18 const char* url, |
| 19 void** ipc_channel_handle) { |
| 18 // send a synchronous message to the browser process | 20 // send a synchronous message to the browser process |
| 19 // TODO(sehr): This is asserted to be one. Remove this parameter. | 21 // TODO(sehr): This is asserted to be one. Remove this parameter. |
| 20 static const int kNumberOfChannelsToBeCreated = 1; | 22 static const int kNumberOfChannelsToBeCreated = 1; |
| 21 if (!launch_nacl_process || | 23 if (!launch_nacl_process || |
| 22 !launch_nacl_process(instance, | 24 !launch_nacl_process(instance, |
| 23 url, | 25 url, |
| 24 kNumberOfChannelsToBeCreated, | 26 kNumberOfChannelsToBeCreated, |
| 25 &channel_)) { | 27 &channel_, |
| 28 ipc_channel_handle)) { |
| 26 return false; | 29 return false; |
| 27 } | 30 } |
| 28 return true; | 31 return true; |
| 29 } | 32 } |
| 30 | 33 |
| 31 } // namespace plugin | 34 } // namespace plugin |
| OLD | NEW |