diff options
author | Pavel Shilovsky <piastry@etersoft.ru> | 2012-11-28 15:27:54 +0400 |
---|---|---|
committer | Steve French <smfrench@gmail.com> | 2012-11-28 10:02:46 -0600 |
commit | c772aa92b6deb2857d4b39a5cc3bd3679cc5f4a6 (patch) | |
tree | 382d75f593ed26f530abca854cf6c7c7b35667ea /fs/cifs/smb1ops.c | |
parent | 3a98b8614312026d489e56c1d0e294a68e2aad77 (diff) |
CIFS: Fix wrong buffer pointer usage in smb_set_file_info
Commit 6bdf6dbd662176c0da5c3ac8ed10ac94e7776c85 caused a regression
in setattr codepath that leads to files with wrong attributes.
Signed-off-by: Pavel Shilovsky <piastry@etersoft.ru>
Reviewed-by: Jeff Layton <jlayton@redhat.com>
Signed-off-by: Steve French <smfrench@gmail.com>
Diffstat (limited to 'fs/cifs/smb1ops.c')
-rw-r--r-- | fs/cifs/smb1ops.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/fs/cifs/smb1ops.c b/fs/cifs/smb1ops.c index 56cc4be87807..34cea2798333 100644 --- a/fs/cifs/smb1ops.c +++ b/fs/cifs/smb1ops.c @@ -766,7 +766,6 @@ smb_set_file_info(struct inode *inode, const char *full_path, struct cifs_sb_info *cifs_sb = CIFS_SB(inode->i_sb); struct tcon_link *tlink = NULL; struct cifs_tcon *tcon; - FILE_BASIC_INFO info_buf; /* if the file is already open for write, just use that fileid */ open_file = find_writable_file(cinode, true); @@ -817,7 +816,7 @@ smb_set_file_info(struct inode *inode, const char *full_path, netpid = current->tgid; set_via_filehandle: - rc = CIFSSMBSetFileInfo(xid, tcon, &info_buf, netfid, netpid); + rc = CIFSSMBSetFileInfo(xid, tcon, buf, netfid, netpid); if (!rc) cinode->cifsAttrs = le32_to_cpu(buf->Attributes); |