OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 "content/browser/renderer_host/pepper_udp_socket.h" | 5 #include "content/browser/renderer_host/pepper_udp_socket.h" |
6 | 6 |
7 #include <string.h> | 7 #include <string.h> |
8 | 8 |
9 #include "base/compiler_specific.h" | 9 #include "base/compiler_specific.h" |
10 #include "base/logging.h" | 10 #include "base/logging.h" |
11 #include "content/browser/renderer_host/pepper_message_filter.h" | 11 #include "content/browser/renderer_host/pepper_message_filter.h" |
12 #include "content/public/browser/browser_thread.h" | 12 #include "content/public/browser/browser_thread.h" |
13 #include "net/base/io_buffer.h" | 13 #include "net/base/io_buffer.h" |
14 #include "net/base/net_errors.h" | 14 #include "net/base/net_errors.h" |
15 #include "net/udp/udp_server_socket.h" | 15 #include "net/udp/udp_server_socket.h" |
16 #include "ppapi/proxy/ppapi_messages.h" | 16 #include "ppapi/proxy/ppapi_messages.h" |
17 #include "ppapi/proxy/ppb_udp_socket_private_proxy.h" | |
18 #include "ppapi/shared_impl/private/net_address_private_impl.h" | 17 #include "ppapi/shared_impl/private/net_address_private_impl.h" |
19 | 18 |
20 using content::BrowserThread; | 19 using content::BrowserThread; |
21 using ppapi::NetAddressPrivateImpl; | 20 using ppapi::NetAddressPrivateImpl; |
22 | 21 |
23 PepperUDPSocket::PepperUDPSocket( | 22 PepperUDPSocket::PepperUDPSocket( |
24 PepperMessageFilter* manager, | 23 PepperMessageFilter* manager, |
25 int32 routing_id, | 24 int32 routing_id, |
26 uint32 plugin_dispatcher_id, | 25 uint32 plugin_dispatcher_id, |
27 uint32 socket_id) | 26 uint32 socket_id) |
(...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
136 } | 135 } |
137 | 136 |
138 void PepperUDPSocket::OnSendToCompleted(int result) { | 137 void PepperUDPSocket::OnSendToCompleted(int result) { |
139 DCHECK(sendto_buffer_.get()); | 138 DCHECK(sendto_buffer_.get()); |
140 | 139 |
141 manager_->Send(new PpapiMsg_PPBUDPSocket_SendToACK( | 140 manager_->Send(new PpapiMsg_PPBUDPSocket_SendToACK( |
142 routing_id_, plugin_dispatcher_id_, socket_id_, true, result)); | 141 routing_id_, plugin_dispatcher_id_, socket_id_, true, result)); |
143 | 142 |
144 sendto_buffer_ = NULL; | 143 sendto_buffer_ = NULL; |
145 } | 144 } |
OLD | NEW |