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

Unified Diff: net/base/listen_socket.h

Issue 368001: Second patch in making destructors of refcounted objects private. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 1 month 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: net/base/listen_socket.h
===================================================================
--- net/base/listen_socket.h (revision 31079)
+++ net/base/listen_socket.h (working copy)
@@ -59,7 +59,6 @@
// accept local connections.
static ListenSocket* Listen(std::string ip, int port,
ListenSocketDelegate* del);
- virtual ~ListenSocket();
// Send data to the socket.
void Send(const char* bytes, int len, bool append_linefeed = false);
@@ -72,10 +71,13 @@
void ResumeReads();
protected:
+ friend class base::RefCountedThreadSafe<ListenSocket>;
+
static const SOCKET kInvalidSocket;
static const int kSocketError;
ListenSocket(SOCKET s, ListenSocketDelegate* del);
+ virtual ~ListenSocket();
static SOCKET Listen(std::string ip, int port);
// if valid, returned SOCKET is non-blocking
static SOCKET Accept(SOCKET s);

Powered by Google App Engine
This is Rietveld 408576698