diff options
-rw-r--r-- | net/socket.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/net/socket.c b/net/socket.c index d2336472f494..379b3a390755 100644 --- a/net/socket.c +++ b/net/socket.c | |||
@@ -2235,6 +2235,7 @@ int kernel_accept(struct socket *sock, struct socket **newsock, int flags) | |||
2235 | err = sock->ops->accept(sock, *newsock, flags); | 2235 | err = sock->ops->accept(sock, *newsock, flags); |
2236 | if (err < 0) { | 2236 | if (err < 0) { |
2237 | sock_release(*newsock); | 2237 | sock_release(*newsock); |
2238 | *newsock = NULL; | ||
2238 | goto done; | 2239 | goto done; |
2239 | } | 2240 | } |
2240 | 2241 | ||