diff options
Diffstat (limited to 'kernel/fs/cifs/smb2file.c')
-rw-r--r-- | kernel/fs/cifs/smb2file.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/kernel/fs/cifs/smb2file.c b/kernel/fs/cifs/smb2file.c index f9e766f46..b2aff0c6f 100644 --- a/kernel/fs/cifs/smb2file.c +++ b/kernel/fs/cifs/smb2file.c @@ -260,7 +260,7 @@ smb2_push_mandatory_locks(struct cifsFileInfo *cfile) * and check it for zero before using. */ max_buf = tlink_tcon(cfile->tlink)->ses->server->maxBuf; - if (!max_buf) { + if (max_buf < sizeof(struct smb2_lock_element)) { free_xid(xid); return -EINVAL; } |