| 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 // Defines messages between the browser and NaCl process. | 5 // Defines messages between the browser and NaCl process. |
| 6 | 6 |
| 7 // Multiply-included message file, no traditional include guard. | 7 // Multiply-included message file, no traditional include guard. |
| 8 #include "base/process.h" | 8 #include "base/process.h" |
| 9 #include "chrome/common/nacl_types.h" | 9 #include "chrome/common/nacl_types.h" |
| 10 #include "ipc/ipc_message_macros.h" | 10 #include "ipc/ipc_message_macros.h" |
| 11 | 11 |
| 12 #ifndef CHROME_COMMON_NACL_MESSAGES_H_ | 12 #define IPC_MESSAGE_START NaClMsgStart |
| 13 #define CHROME_COMMON_NACL_MESSAGES_H_ | |
| 14 | 13 |
| 15 #endif // CHROME_COMMON_NACL_MESSAGES_H_ | 14 IPC_STRUCT_TRAITS_BEGIN(nacl::NaClStartParams) |
| 16 | 15 IPC_STRUCT_TRAITS_MEMBER(sockets) |
| 17 #define IPC_MESSAGE_START NaClMsgStart | 16 IPC_STRUCT_TRAITS_MEMBER(validation_cache_key) |
| 17 IPC_STRUCT_TRAITS_MEMBER(version) |
| 18 IPC_STRUCT_TRAITS_MEMBER(enable_exception_handling) |
| 19 IPC_STRUCT_TRAITS_END() |
| 18 | 20 |
| 19 //----------------------------------------------------------------------------- | 21 //----------------------------------------------------------------------------- |
| 20 // NaClProcess messages | 22 // NaClProcess messages |
| 21 // These are messages sent between the browser and the NaCl process. | 23 // These are messages sent between the browser and the NaCl process. |
| 22 // Tells the NaCl process to start. | 24 // Tells the NaCl process to start. |
| 23 IPC_MESSAGE_CONTROL4(NaClProcessMsg_Start, | 25 IPC_MESSAGE_CONTROL1(NaClProcessMsg_Start, |
| 24 std::vector<nacl::FileDescriptor> /* sockets */, | 26 nacl::NaClStartParams /* params */) |
| 25 std::string /* validation_cache_key */, | |
| 26 std::string /* version */, | |
| 27 bool /* enable_exception_handling */) | |
| 28 | 27 |
| 29 // Tells the NaCl broker to launch a NaCl loader process. | 28 // Tells the NaCl broker to launch a NaCl loader process. |
| 30 IPC_MESSAGE_CONTROL1(NaClProcessMsg_LaunchLoaderThroughBroker, | 29 IPC_MESSAGE_CONTROL1(NaClProcessMsg_LaunchLoaderThroughBroker, |
| 31 std::string /* channel ID for the loader */) | 30 std::string /* channel ID for the loader */) |
| 32 | 31 |
| 33 // Notify the browser process that the loader was launched successfully. | 32 // Notify the browser process that the loader was launched successfully. |
| 34 IPC_MESSAGE_CONTROL2(NaClProcessMsg_LoaderLaunched, | 33 IPC_MESSAGE_CONTROL2(NaClProcessMsg_LoaderLaunched, |
| 35 std::string, /* channel ID for the loader */ | 34 std::string, /* channel ID for the loader */ |
| 36 base::ProcessHandle /* loader process handle */) | 35 base::ProcessHandle /* loader process handle */) |
| 37 | 36 |
| (...skipping 15 matching lines...) Expand all Loading... |
| 53 // Used by the NaCl process to query a database in the browser. The database | 52 // Used by the NaCl process to query a database in the browser. The database |
| 54 // contains the signatures of previously validated code chunks. | 53 // contains the signatures of previously validated code chunks. |
| 55 IPC_SYNC_MESSAGE_CONTROL1_1(NaClProcessMsg_QueryKnownToValidate, | 54 IPC_SYNC_MESSAGE_CONTROL1_1(NaClProcessMsg_QueryKnownToValidate, |
| 56 std::string, /* A validation signature */ | 55 std::string, /* A validation signature */ |
| 57 bool /* Can validation be skipped? */) | 56 bool /* Can validation be skipped? */) |
| 58 | 57 |
| 59 // Used by the NaCl process to add a validation signature to the validation | 58 // Used by the NaCl process to add a validation signature to the validation |
| 60 // database in the browser. | 59 // database in the browser. |
| 61 IPC_MESSAGE_CONTROL1(NaClProcessMsg_SetKnownToValidate, | 60 IPC_MESSAGE_CONTROL1(NaClProcessMsg_SetKnownToValidate, |
| 62 std::string /* A validation signature */) | 61 std::string /* A validation signature */) |
| OLD | NEW |