DORMANTno replies

[PATCH 4/7] librdmacm/rspreload: Minor cleanup of fork_passive handling

From: Hefty, Sean <hidden>
Date: 2012-08-16 19:24:23
Subsystem: the rest · Maintainer: Linus Torvalds

Minor code cleanup in passive side handling of fork support.

Signed-off-by: Sean Hefty <redacted>
---
 src/preload.c |    7 ++-----
 1 files changed, 2 insertions(+), 5 deletions(-)
diff --git a/src/preload.c b/src/preload.c
index b18d310..bb8e3fb 100644
--- a/src/preload.c
+++ b/src/preload.c
@@ -492,7 +492,7 @@ static void fork_passive(int socket)
 	socklen_t len;
 	uint32_t msg;
 
-	fd_get(socket, &sfd);
+	sfd = fd_getd(socket);
 
 	len = sizeof sin6;
 	ret = real.getsockname(sfd, (struct sockaddr *) &sin6, &len);
@@ -510,7 +510,7 @@ static void fork_passive(int socket)
 
 	lfd = rsocket(sin6.sin6_family, SOCK_STREAM, 0);
 	if (lfd < 0) {
-		ret  = lfd;
+		ret = lfd;
 		goto sclose;
 	}
 
@@ -537,10 +537,7 @@ static void fork_passive(int socket)
 		goto lclose;
 	}
 
-	param = 1;
-	rsetsockopt(dfd, IPPROTO_TCP, TCP_NODELAY, &param, sizeof param);
 	set_rsocket_options(dfd);
-
 	copysockopts(dfd, sfd, &rs, &real);
 	real.shutdown(sfd, SHUT_RDWR);
 	real.close(sfd);


--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help