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

Unified Diff: chrome/browser/extensions/api/socket/socket.cc

Issue 10827390: Implement chrome.socket.bind/listen/accept for TCP server socket. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Remove need to bind before calling listen. Created 8 years, 3 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
Index: chrome/browser/extensions/api/socket/socket.cc
diff --git a/chrome/browser/extensions/api/socket/socket.cc b/chrome/browser/extensions/api/socket/socket.cc
index 3d297217896471e1bcdcdc04a870891dc1532d70..34bb4f5dfe6a562b6b62383ab4f6c1374bb460a1 100644
--- a/chrome/browser/extensions/api/socket/socket.cc
+++ b/chrome/browser/extensions/api/socket/socket.cc
@@ -87,6 +87,15 @@ bool Socket::SetNoDelay(bool no_delay) {
return false;
}
+int Socket::Listen(const std::string& address, int port, int backlog,
+ std::string* error_msg) {
+ return net::ERR_NOT_IMPLEMENTED;
+}
+
+void Socket::Accept(const AcceptCompletionCallback& callback) {
+ callback.Run(net::ERR_NOT_IMPLEMENTED, NULL);
+}
+
// static
bool Socket::StringAndPortToIPEndPoint(const std::string& ip_address_str,
int port,

Powered by Google App Engine
This is Rietveld 408576698