* [PATCH] sctp: sm_statefuns: Remove unnecessary ‘NULL’ values from Pointer
@ 2022-11-15 1:55 Li zeming
2022-11-17 12:13 ` Paolo Abeni
0 siblings, 1 reply; 3+ messages in thread
From: Li zeming @ 2022-11-15 1:55 UTC (permalink / raw)
To: vyasevich, nhorman, marcelo.leitner, davem, edumazet, kuba, pabeni
Cc: linux-sctp, netdev, linux-kernel, Li zeming
The packet pointer is assigned first. It does not need to initialize the
assignment.
Signed-off-by: Li zeming <zeming@nfschina.com>
---
net/sctp/sm_statefuns.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/net/sctp/sm_statefuns.c b/net/sctp/sm_statefuns.c
index f6ee7f4040c1..714605746fee 100644
--- a/net/sctp/sm_statefuns.c
+++ b/net/sctp/sm_statefuns.c
@@ -3781,7 +3781,7 @@ static enum sctp_disposition sctp_sf_shut_8_4_5(
void *arg,
struct sctp_cmd_seq *commands)
{
- struct sctp_packet *packet = NULL;
+ struct sctp_packet *packet;
struct sctp_chunk *chunk = arg;
struct sctp_chunk *shut;
--
2.18.2
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] sctp: sm_statefuns: Remove unnecessary ‘NULL’ values from Pointer
2022-11-15 1:55 [PATCH] sctp: sm_statefuns: Remove unnecessary ‘NULL’ values from Pointer Li zeming
@ 2022-11-17 12:13 ` Paolo Abeni
2022-11-18 1:35 ` Li zeming
0 siblings, 1 reply; 3+ messages in thread
From: Paolo Abeni @ 2022-11-17 12:13 UTC (permalink / raw)
To: Li zeming, vyasevich, nhorman, marcelo.leitner, davem, edumazet, kuba
Cc: linux-sctp, netdev, linux-kernel
Hi,
On Tue, 2022-11-15 at 09:55 +0800, Li zeming wrote:
> The packet pointer is assigned first. It does not need to initialize the
> assignment.
>
> Signed-off-by: Li zeming <zeming@nfschina.com>
I'm sorry, but IMHO the commit message is quite unclear, I suggest to
re-phrase to something alike:
"""
The 'packet' pointer is always set in the later code, no need to
initialize it at definition time.
"""
Thanks,
Paolo
^ permalink raw reply [flat|nested] 3+ messages in thread
* (no subject)
2022-11-17 12:13 ` Paolo Abeni
@ 2022-11-18 1:35 ` Li zeming
0 siblings, 0 replies; 3+ messages in thread
From: Li zeming @ 2022-11-18 1:35 UTC (permalink / raw)
To: pabeni
Cc: davem, edumazet, kuba, linux-kernel, linux-sctp, marcelo.leitner,
netdev, nhorman, vyasevich
Many thanks. I resubmit a patch.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2022-11-18 1:37 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-11-15 1:55 [PATCH] sctp: sm_statefuns: Remove unnecessary ‘NULL’ values from Pointer Li zeming
2022-11-17 12:13 ` Paolo Abeni
2022-11-18 1:35 ` Li zeming
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.