diff mbox series

smb3: use SMB2_SIGNATURE_SIZE define

Message ID CAH2r5muYwx1TvdmJo5H2aXfzDXc2VP4u-=UeFA53cwiO3ZB+EQ@mail.gmail.com (mailing list archive)
State New, archived
Headers show
Series smb3: use SMB2_SIGNATURE_SIZE define | expand

Commit Message

Steve French March 27, 2020, 5:55 p.m. UTC

Comments

Henning Schild March 27, 2020, 7:41 p.m. UTC | #1
maybe sizeofs for the memc(mp|py)s would be a good addition

Henning
diff mbox series

Patch

From edad734c74a4ab6ba8531186054779b2382df3fd Mon Sep 17 00:00:00 2001
From: Steve French <stfrench@microsoft.com>
Date: Fri, 27 Mar 2020 12:47:41 -0500
Subject: [PATCH] smb3: use SMB2_SIGNATURE_SIZE define

It clarifies the code slightly to use SMB2_SIGNATURE_SIZE
define rather than 16.

Suggested-by: Henning Schild <henning.schild@siemens.com>
Signed-off-by: Steve French <stfrench@microsoft.com>
---
 fs/cifs/smb2transport.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/fs/cifs/smb2transport.c b/fs/cifs/smb2transport.c
index 08b703b7a15e..2b67a7769d74 100644
--- a/fs/cifs/smb2transport.c
+++ b/fs/cifs/smb2transport.c
@@ -602,7 +602,7 @@  int
 smb2_verify_signature(struct smb_rqst *rqst, struct TCP_Server_Info *server)
 {
 	unsigned int rc;
-	char server_response_sig[16];
+	char server_response_sig[SMB2_SIGNATURE_SIZE];
 	struct smb2_sync_hdr *shdr =
 			(struct smb2_sync_hdr *)rqst->rq_iov[0].iov_base;
 
-- 
2.20.1