[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <811ba34fc96b2ec46105af451be97cf87eb410f3.1681917361.git.lucien.xin@gmail.com>
Date: Wed, 19 Apr 2023 11:16:33 -0400
From: Xin Long <lucien.xin@...il.com>
To: network dev <netdev@...r.kernel.org>, linux-sctp@...r.kernel.org
Cc: davem@...emloft.net, kuba@...nel.org,
Eric Dumazet <edumazet@...gle.com>,
Paolo Abeni <pabeni@...hat.com>,
Marcelo Ricardo Leitner <marcelo.leitner@...il.com>
Subject: [PATCH net-next 6/6] sctp: delete the nested flexible array payload
This patch deletes the flexible-array payload[] from the structure
sctp_datahdr to avoid some sparse warnings:
# make C=2 CF="-Wflexible-array-nested" M=./net/sctp/
net/sctp/socket.c: note: in included file (through include/net/sctp/structs.h, include/net/sctp/sctp.h):
./include/linux/sctp.h:230:29: warning: nested flexible array
This member is not even used anywhere.
Signed-off-by: Xin Long <lucien.xin@...il.com>
---
include/linux/sctp.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/include/linux/sctp.h b/include/linux/sctp.h
index d182e8c41985..836a7e200f39 100644
--- a/include/linux/sctp.h
+++ b/include/linux/sctp.h
@@ -222,7 +222,7 @@ struct sctp_datahdr {
__be16 stream;
__be16 ssn;
__u32 ppid;
- __u8 payload[];
+ /* __u8 payload[]; */
};
struct sctp_data_chunk {
--
2.39.1
Powered by blists - more mailing lists