summaryrefslogtreecommitdiff
path: root/fs/cifs/dir.c
diff options
context:
space:
mode:
authorSteve French <stfrench@microsoft.com>2022-10-14 19:18:32 -0500
committerSteve French <stfrench@microsoft.com>2022-10-15 10:05:53 -0500
commit625b60d4f9517903ad499633776825e67fdb0c16 (patch)
treeec9acbbed2b44b9ae45a8f07268d7c2d5dfeb748 /fs/cifs/dir.c
parentf09bd695af3b8ab46fc24e5d6954a24104c38387 (diff)
cifs: lease key is uninitialized in smb1 paths
It is cleaner to set lease key to zero in the places where leases are not supported (smb1 can not return lease keys so the field was uninitialized). Addresses-Coverity: 1513994 ("Uninitialized scalar variable") Reviewed-by: Paulo Alcantara (SUSE) <pc@cjr.nz> Signed-off-by: Steve French <stfrench@microsoft.com>
Diffstat (limited to 'fs/cifs/dir.c')
-rw-r--r--fs/cifs/dir.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/cifs/dir.c b/fs/cifs/dir.c
index cbd46ac59cd2..a5c73c2af3a2 100644
--- a/fs/cifs/dir.c
+++ b/fs/cifs/dir.c
@@ -413,7 +413,7 @@ cifs_atomic_open(struct inode *inode, struct dentry *direntry,
struct tcon_link *tlink;
struct cifs_tcon *tcon;
struct TCP_Server_Info *server;
- struct cifs_fid fid;
+ struct cifs_fid fid = {};
struct cifs_pending_open open;
__u32 oplock;
struct cifsFileInfo *file_info;