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

Unified Diff: net/base/tcp_listen_socket_unittest.h

Issue 10161005: Add DefaultListenSocket. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix build on Windows Created 8 years, 7 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 | « net/base/tcp_listen_socket.cc ('k') | net/base/tcp_listen_socket_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/base/tcp_listen_socket_unittest.h
diff --git a/net/base/tcp_listen_socket_unittest.h b/net/base/tcp_listen_socket_unittest.h
index a8c2b893f454ed08b31c5ddafd3f4d3ef070d48e..71870f78a12b966137995c20784ea54c4af79477 100644
--- a/net/base/tcp_listen_socket_unittest.h
+++ b/net/base/tcp_listen_socket_unittest.h
@@ -17,6 +17,7 @@
#endif
#include "base/basictypes.h"
+#include "base/memory/ref_counted.h"
#include "base/memory/scoped_ptr.h"
#include "base/message_loop.h"
#include "base/string_util.h"
@@ -67,7 +68,7 @@ class TCPListenSocketTestAction {
// This had to be split out into a separate class because I couldn't
// make the testing::Test class refcounted.
class TCPListenSocketTester :
- public ListenSocket::ListenSocketDelegate,
+ public StreamListenSocket::Delegate,
public base::RefCountedThreadSafe<TCPListenSocketTester> {
public:
@@ -96,17 +97,17 @@ class TCPListenSocketTester :
virtual bool Send(SOCKET sock, const std::string& str);
- // ListenSocket::ListenSocketDelegate:
- virtual void DidAccept(ListenSocket *server,
- ListenSocket *connection) OVERRIDE;
- virtual void DidRead(ListenSocket *connection, const char* data,
+ // StreamListenSocket::Delegate:
+ virtual void DidAccept(StreamListenSocket* server,
+ StreamListenSocket* connection) OVERRIDE;
+ virtual void DidRead(StreamListenSocket* connection, const char* data,
int len) OVERRIDE;
- virtual void DidClose(ListenSocket *sock) OVERRIDE;
+ virtual void DidClose(StreamListenSocket* sock) OVERRIDE;
scoped_ptr<base::Thread> thread_;
MessageLoopForIO* loop_;
- TCPListenSocket* server_;
- ListenSocket* connection_;
+ scoped_refptr<TCPListenSocket> server_;
+ StreamListenSocket* connection_;
TCPListenSocketTestAction last_action_;
SOCKET test_socket_;
@@ -121,7 +122,7 @@ class TCPListenSocketTester :
virtual ~TCPListenSocketTester();
- virtual TCPListenSocket* DoListen();
+ virtual scoped_refptr<TCPListenSocket> DoListen();
};
} // namespace net
« no previous file with comments | « net/base/tcp_listen_socket.cc ('k') | net/base/tcp_listen_socket_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698