Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2951)

Unified Diff: webkit/plugins/ppapi/ppb_udp_socket_private_impl.cc

Issue 10735056: AllowBroadcast() is exposed to NaCl. (Closed) Base URL: http://git.chromium.org/chromium/src.git@udp_broadcast
Patch Set: Sync. Created 8 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « webkit/plugins/ppapi/ppb_udp_socket_private_impl.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/plugins/ppapi/ppb_udp_socket_private_impl.cc
diff --git a/webkit/plugins/ppapi/ppb_udp_socket_private_impl.cc b/webkit/plugins/ppapi/ppb_udp_socket_private_impl.cc
index 772746fab4e4b3e6d3c60e578cd944af7a906971..a656ef71212e109d4c820a26efae9e40fe294b2b 100644
--- a/webkit/plugins/ppapi/ppb_udp_socket_private_impl.cc
+++ b/webkit/plugins/ppapi/ppb_udp_socket_private_impl.cc
@@ -1,4 +1,4 @@
-// Copyright (c) 2011 The Chromium Authors. All rights reserved.
+// Copyright (c) 2012 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
@@ -26,45 +26,54 @@ PP_Resource PPB_UDPSocket_Private_Impl::CreateResource(PP_Instance instance) {
if (!plugin_instance)
return 0;
- PluginDelegate* pluign_delegate = plugin_instance->delegate();
- uint32 socket_id = pluign_delegate->UDPSocketCreate();
+ PluginDelegate* plugin_delegate = plugin_instance->delegate();
+ uint32 socket_id = plugin_delegate->UDPSocketCreate();
if (!socket_id)
return 0;
return (new PPB_UDPSocket_Private_Impl(instance, socket_id))->GetReference();
}
+void PPB_UDPSocket_Private_Impl::SendBoolSocketFeature(int32_t name,
+ bool value) {
+ PluginDelegate* plugin_delegate = ResourceHelper::GetPluginDelegate(this);
+ if (!plugin_delegate)
+ return;
+
+ plugin_delegate->UDPSocketSetBoolSocketFeature(this, socket_id_, name, value);
+}
+
void PPB_UDPSocket_Private_Impl::SendBind(const PP_NetAddress_Private& addr) {
- PluginDelegate* pluign_delegate = ResourceHelper::GetPluginDelegate(this);
- if (!pluign_delegate)
+ PluginDelegate* plugin_delegate = ResourceHelper::GetPluginDelegate(this);
+ if (!plugin_delegate)
return;
- pluign_delegate->UDPSocketBind(this, socket_id_, addr);
+ plugin_delegate->UDPSocketBind(this, socket_id_, addr);
}
void PPB_UDPSocket_Private_Impl::SendRecvFrom(int32_t num_bytes) {
- PluginDelegate* pluign_delegate = ResourceHelper::GetPluginDelegate(this);
- if (!pluign_delegate)
+ PluginDelegate* plugin_delegate = ResourceHelper::GetPluginDelegate(this);
+ if (!plugin_delegate)
return;
- pluign_delegate->UDPSocketRecvFrom(socket_id_, num_bytes);
+ plugin_delegate->UDPSocketRecvFrom(socket_id_, num_bytes);
}
void PPB_UDPSocket_Private_Impl::SendSendTo(const std::string& buffer,
const PP_NetAddress_Private& addr) {
- PluginDelegate* pluign_delegate = ResourceHelper::GetPluginDelegate(this);
- if (!pluign_delegate)
+ PluginDelegate* plugin_delegate = ResourceHelper::GetPluginDelegate(this);
+ if (!plugin_delegate)
return;
- pluign_delegate->UDPSocketSendTo(socket_id_, buffer, addr);
+ plugin_delegate->UDPSocketSendTo(socket_id_, buffer, addr);
}
void PPB_UDPSocket_Private_Impl::SendClose() {
- PluginDelegate* pluign_delegate = ResourceHelper::GetPluginDelegate(this);
- if (!pluign_delegate)
+ PluginDelegate* plugin_delegate = ResourceHelper::GetPluginDelegate(this);
+ if (!plugin_delegate)
return;
- pluign_delegate->UDPSocketClose(socket_id_);
+ plugin_delegate->UDPSocketClose(socket_id_);
}
} // namespace ppapi
« no previous file with comments | « webkit/plugins/ppapi/ppb_udp_socket_private_impl.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698