Skip to content

Commit f0a5818

Browse files
Yang Lidavem330
authored andcommitted
vsock/vmci: Remove redundant assignment to err
Variable 'err' is set to zero but this value is never read as it is overwritten with a new value later on, hence it is a redundant assignment and can be removed. Clean up the following clang-analyzer warning: net/vmw_vsock/vmci_transport.c:948:2: warning: Value stored to 'err' is never read [clang-analyzer-deadcode.DeadStores] Reported-by: Abaci Robot <[email protected]> Signed-off-by: Yang Li <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent 00207c7 commit f0a5818

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

net/vmw_vsock/vmci_transport.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -944,8 +944,6 @@ static int vmci_transport_recv_listen(struct sock *sk,
944944
bool old_request = false;
945945
bool old_pkt_proto = false;
946946

947-
err = 0;
948-
949947
/* Because we are in the listen state, we could be receiving a packet
950948
* for ourself or any previous connection requests that we received.
951949
* If it's the latter, we try to find a socket in our list of pending

0 commit comments

Comments
 (0)