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

Unified Diff: net/socket/unix_domain_client_socket_posix.cc

Issue 509133002: Raw SocketDescriptor variant of UnixDomainServerSocket::Accept (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address nits; waiting on mmenke for broader comments. Created 6 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: net/socket/unix_domain_client_socket_posix.cc
diff --git a/net/socket/unix_domain_client_socket_posix.cc b/net/socket/unix_domain_client_socket_posix.cc
index 92fab6faa4189071fa01519c5825ff6b623f2307..fa2395f0d45857b61b98837c3cbc1cb3346626fb 100644
--- a/net/socket/unix_domain_client_socket_posix.cc
+++ b/net/socket/unix_domain_client_socket_posix.cc
@@ -159,4 +159,13 @@ int UnixDomainClientSocket::SetSendBufferSize(int32 size) {
return ERR_NOT_IMPLEMENTED;
}
+SocketDescriptor UnixDomainClientSocket::ReleaseSocketDescriptor() {
+ if (!socket_)
+ return kInvalidSocket;
+
+ SocketDescriptor socket_fd = socket_->ReleaseConnectedSocket();
mmenke 2014/09/03 14:56:46 Should use a consistent temp name here and in Rele
Chris Masone 2014/09/03 15:57:11 Done.
+ socket_.reset();
+ return socket_fd;
+}
+
} // namespace net

Powered by Google App Engine
This is Rietveld 408576698