OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 "ppapi/proxy/nacl_message_scanner.h" | 5 #include "ppapi/proxy/nacl_message_scanner.h" |
6 | 6 |
7 #include <vector> | 7 #include <vector> |
8 #include "base/bind.h" | 8 #include "base/bind.h" |
9 #include "ipc/ipc_message.h" | 9 #include "ipc/ipc_message.h" |
10 #include "ipc/ipc_message_macros.h" | 10 #include "ipc/ipc_message_macros.h" |
(...skipping 300 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
311 // that there are no handles, we can cancel the rewriting by clearing the | 311 // that there are no handles, we can cancel the rewriting by clearing the |
312 // results.new_msg pointer. | 312 // results.new_msg pointer. |
313 ScanningResults results; | 313 ScanningResults results; |
314 results.nested_msg_callback = | 314 results.nested_msg_callback = |
315 base::Bind(&NaClMessageScanner::AuditNestedMessage, | 315 base::Bind(&NaClMessageScanner::AuditNestedMessage, |
316 base::Unretained(this)); | 316 base::Unretained(this)); |
317 switch (type) { | 317 switch (type) { |
318 CASE_FOR_MESSAGE(PpapiMsg_PPBAudio_NotifyAudioStreamCreated) | 318 CASE_FOR_MESSAGE(PpapiMsg_PPBAudio_NotifyAudioStreamCreated) |
319 CASE_FOR_MESSAGE(PpapiMsg_PPPMessaging_HandleMessage) | 319 CASE_FOR_MESSAGE(PpapiMsg_PPPMessaging_HandleMessage) |
320 CASE_FOR_MESSAGE(PpapiPluginMsg_ResourceReply) | 320 CASE_FOR_MESSAGE(PpapiPluginMsg_ResourceReply) |
| 321 CASE_FOR_REPLY(PpapiHostMsg_PPBGraphics3D_Create) |
321 CASE_FOR_REPLY(PpapiHostMsg_PPBGraphics3D_CreateTransferBuffer) | 322 CASE_FOR_REPLY(PpapiHostMsg_PPBGraphics3D_CreateTransferBuffer) |
322 CASE_FOR_REPLY(PpapiHostMsg_PPBImageData_CreateSimple) | 323 CASE_FOR_REPLY(PpapiHostMsg_PPBImageData_CreateSimple) |
323 CASE_FOR_REPLY(PpapiHostMsg_ResourceSyncCall) | 324 CASE_FOR_REPLY(PpapiHostMsg_ResourceSyncCall) |
324 CASE_FOR_REPLY(PpapiHostMsg_SharedMemory_CreateSharedMemory) | 325 CASE_FOR_REPLY(PpapiHostMsg_SharedMemory_CreateSharedMemory) |
325 default: | 326 default: |
326 // Do nothing for messages we don't know. | 327 // Do nothing for messages we don't know. |
327 break; | 328 break; |
328 } | 329 } |
329 | 330 |
330 // Only messages containing handles need to be rewritten. If no handles are | 331 // Only messages containing handles need to be rewritten. If no handles are |
(...skipping 178 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
509 fio_it->second->SetMaxWrittenOffset(offset_it->second); | 510 fio_it->second->SetMaxWrittenOffset(offset_it->second); |
510 } | 511 } |
511 } | 512 } |
512 break; | 513 break; |
513 } | 514 } |
514 } | 515 } |
515 } | 516 } |
516 | 517 |
517 } // namespace proxy | 518 } // namespace proxy |
518 } // namespace ppapi | 519 } // namespace ppapi |
OLD | NEW |