Skip to content

Commit d099b8a

Browse files
Colin Ian Kingtrondmypd
authored andcommitted
sunrpc: remove redundant initialization of sock
sock is being initialized and then being almost immediately updated hence the initialized value is not being used and is redundant. Remove the initialization. Cleans up clang warning: warning: Value stored to 'sock' during its initialization is never read Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com>
1 parent 68ebf8f commit d099b8a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

net/sunrpc/xprtsock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2203,7 +2203,7 @@ static void xs_udp_setup_socket(struct work_struct *work)
22032203
struct sock_xprt *transport =
22042204
container_of(work, struct sock_xprt, connect_worker.work);
22052205
struct rpc_xprt *xprt = &transport->xprt;
2206-
struct socket *sock = transport->sock;
2206+
struct socket *sock;
22072207
int status = -EIO;
22082208

22092209
sock = xs_create_sock(xprt, transport,

0 commit comments

Comments
 (0)