Skip to content

Commit 9f544d2

Browse files
Paulo AlcantaraSteve French
authored andcommitted
smb: client: get rid of bounds check in SMB2_ioctl_init()
smb2_set_next_command() no longer squashes request iovs into a single iov, so the bounds check can be dropped. Cc: David Howells <[email protected]> Signed-off-by: Paulo Alcantara (Red Hat) <[email protected]> Signed-off-by: Steve French <[email protected]>
1 parent bc925c1 commit 9f544d2

File tree

1 file changed

+0
-9
lines changed

1 file changed

+0
-9
lines changed

fs/smb/client/smb2pdu.c

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -3313,15 +3313,6 @@ SMB2_ioctl_init(struct cifs_tcon *tcon, struct TCP_Server_Info *server,
33133313
return rc;
33143314

33153315
if (indatalen) {
3316-
unsigned int len;
3317-
3318-
if (WARN_ON_ONCE(smb3_encryption_required(tcon) &&
3319-
(check_add_overflow(total_len - 1,
3320-
ALIGN(indatalen, 8), &len) ||
3321-
len > MAX_CIFS_SMALL_BUFFER_SIZE))) {
3322-
cifs_small_buf_release(req);
3323-
return -EIO;
3324-
}
33253316
/*
33263317
* indatalen is usually small at a couple of bytes max, so
33273318
* just allocate through generic pool

0 commit comments

Comments
 (0)