Skip to content

Commit 11d5e20

Browse files
GustavoARSilvaSteve French
authored andcommitted
ksmbd: Replace one-element array with flexible-array member
One-element arrays are deprecated, and we are replacing them with flexible array members instead. So, replace one-element array with flexible-array member in struct smb_negotiate_req. This results in no differences in binary output. Link: KSPP/linux#79 Link: KSPP/linux#317 Signed-off-by: Gustavo A. R. Silva <[email protected]> Reviewed-by: Kees Cook <[email protected]> Acked-by: Namjae Jeon <[email protected]> Reviewed-by: Sergey Senozhatsky <[email protected]> Signed-off-by: Steve French <[email protected]>
1 parent 5211cc8 commit 11d5e20

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

fs/smb/server/smb_common.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -200,7 +200,7 @@ struct smb_hdr {
200200
struct smb_negotiate_req {
201201
struct smb_hdr hdr; /* wct = 0 */
202202
__le16 ByteCount;
203-
unsigned char DialectsArray[1];
203+
unsigned char DialectsArray[];
204204
} __packed;
205205

206206
struct smb_negotiate_rsp {

0 commit comments

Comments
 (0)