Skip to content

Commit 11e1706

Browse files
dhowellsdavem330
authored andcommitted
rxrpc: rxperf: Fix uninitialised variable
Dan Carpenter sayeth[1]: The patch 75bfdbf: "rxrpc: Implement an in-kernel rxperf server for testing purposes" from Nov 3, 2022, leads to the following Smatch static checker warning: net/rxrpc/rxperf.c:337 rxperf_deliver_to_call() error: uninitialized symbol 'ret'. Fix this by initialising ret to 0. The value is only used for tracing purposes in the rxperf server. Fixes: 75bfdbf ("rxrpc: Implement an in-kernel rxperf server for testing purposes") Reported-by: Dan Carpenter <[email protected]> Signed-off-by: David Howells <[email protected]> cc: Marc Dionne <[email protected]> cc: [email protected] Link: http://lists.infradead.org/pipermail/linux-afs/2022-December/006124.html [1] Signed-off-by: David S. Miller <[email protected]>
1 parent 743d176 commit 11e1706

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

net/rxrpc/rxperf.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -275,7 +275,7 @@ static void rxperf_deliver_to_call(struct work_struct *work)
275275
struct rxperf_call *call = container_of(work, struct rxperf_call, work);
276276
enum rxperf_call_state state;
277277
u32 abort_code, remote_abort = 0;
278-
int ret;
278+
int ret = 0;
279279

280280
if (call->state == RXPERF_CALL_COMPLETE)
281281
return;

0 commit comments

Comments
 (0)