diff options
author | sergeyu@chromium.org <sergeyu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-05-27 19:39:39 +0000 |
---|---|---|
committer | sergeyu@chromium.org <sergeyu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-05-27 19:39:39 +0000 |
commit | eddf10e99b05dc800637c39c4f7e89faba3e616a (patch) | |
tree | 90b3179dc20234af95ace693dec93ba62e117c36 /net/socket/tcp_client_socket_libevent.h | |
parent | f443d9e856f6b7f714cf719bd8596c00af619308 (diff) | |
download | chromium_src-eddf10e99b05dc800637c39c4f7e89faba3e616a.zip chromium_src-eddf10e99b05dc800637c39c4f7e89faba3e616a.tar.gz chromium_src-eddf10e99b05dc800637c39c4f7e89faba3e616a.tar.bz2 |
Revert 87066 - Bind() methods for TCP sockets
BUG=80245
TEST=None
Review URL: http://codereview.chromium.org/7004055
TBR=sergeyu@chromium.org
Review URL: http://codereview.chromium.org/7087004
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@87070 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net/socket/tcp_client_socket_libevent.h')
-rw-r--r-- | net/socket/tcp_client_socket_libevent.h | 18 |
1 files changed, 7 insertions, 11 deletions
diff --git a/net/socket/tcp_client_socket_libevent.h b/net/socket/tcp_client_socket_libevent.h index b9bc557..45f24c2 100644 --- a/net/socket/tcp_client_socket_libevent.h +++ b/net/socket/tcp_client_socket_libevent.h @@ -38,10 +38,7 @@ class TCPClientSocketLibevent : public StreamSocket, base::NonThreadSafe { // the given socket and then acts as if Connect() had been called. This // function is used by TCPServerSocket() to adopt accepted connections // and for testing. - int AdoptSocket(int socket); - - // Binds the socket to a local IP address and port. - int Bind(const IPEndPoint& address); + void AdoptSocket(int socket); // StreamSocket methods: virtual int Connect(CompletionCallback* callback); @@ -133,6 +130,12 @@ class TCPClientSocketLibevent : public StreamSocket, base::NonThreadSafe { return next_connect_state_ != CONNECT_STATE_NONE; } + // Returns the OS error code (or 0 on success). + int CreateSocket(const struct addrinfo* ai); + + // Returns the OS error code (or 0 on success). + int SetupSocket(); + // Helper to add a TCP_CONNECT (end) event to the NetLog. void LogConnectCompletion(int net_error); @@ -141,13 +144,6 @@ class TCPClientSocketLibevent : public StreamSocket, base::NonThreadSafe { int socket_; - // Local IP address and port we are bound to. Set to NULL if Bind() - // was't called (in that cases OS chooses address/port). - scoped_ptr<IPEndPoint> bind_address_; - - // Stores bound socket between Bind() and Connect() calls. - int bound_socket_; - // The list of addresses we should try in order to establish a connection. AddressList addresses_; |