summaryrefslogtreecommitdiffstats
path: root/net/socket/tcp_client_socket_libevent.h
diff options
context:
space:
mode:
authorjhawkins@chromium.org <jhawkins@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-12-07 02:03:33 +0000
committerjhawkins@chromium.org <jhawkins@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-12-07 02:03:33 +0000
commit3f55aa10587b3eaa629d7e95de87998b399fe3e2 (patch)
tree0f407a7e7fc837bed337a9a5af787edbd9473ef6 /net/socket/tcp_client_socket_libevent.h
parentb456003a580041d83e7f5a998c15f62ce380560f (diff)
downloadchromium_src-3f55aa10587b3eaa629d7e95de87998b399fe3e2.zip
chromium_src-3f55aa10587b3eaa629d7e95de87998b399fe3e2.tar.gz
chromium_src-3f55aa10587b3eaa629d7e95de87998b399fe3e2.tar.bz2
base::Bind: Convert Socket::Read.
BUG=none TEST=none R=csilv Review URL: http://codereview.chromium.org/8801005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@113326 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net/socket/tcp_client_socket_libevent.h')
-rw-r--r--net/socket/tcp_client_socket_libevent.h8
1 files changed, 6 insertions, 2 deletions
diff --git a/net/socket/tcp_client_socket_libevent.h b/net/socket/tcp_client_socket_libevent.h
index ac73f2c..47f19a0 100644
--- a/net/socket/tcp_client_socket_libevent.h
+++ b/net/socket/tcp_client_socket_libevent.h
@@ -64,6 +64,9 @@ class NET_EXPORT_PRIVATE TCPClientSocketLibevent : public StreamSocket,
virtual int Read(IOBuffer* buf,
int buf_len,
OldCompletionCallback* callback) OVERRIDE;
+ virtual int Read(IOBuffer* buf,
+ int buf_len,
+ const CompletionCallback& callback) OVERRIDE;
virtual int Write(IOBuffer* buf,
int buf_len,
OldCompletionCallback* callback) OVERRIDE;
@@ -85,7 +88,7 @@ class NET_EXPORT_PRIVATE TCPClientSocketLibevent : public StreamSocket,
// MessageLoopForIO::Watcher methods
virtual void OnFileCanReadWithoutBlocking(int /* fd */) OVERRIDE {
- if (socket_->read_callback_)
+ if (socket_->old_read_callback_)
socket_->DidCompleteRead();
}
@@ -176,7 +179,8 @@ class NET_EXPORT_PRIVATE TCPClientSocketLibevent : public StreamSocket,
int write_buf_len_;
// External callback; called when read is complete.
- OldCompletionCallback* read_callback_;
+ OldCompletionCallback* old_read_callback_;
+ CompletionCallback read_callback_;
// External callback; called when write is complete.
OldCompletionCallback* old_write_callback_;