Skip to content

Commit

Permalink
[PATCH] fs/smbfs/proc.c: fix data corruption in smb_proc_setattr_unix()
Browse files Browse the repository at this point in the history
This patch fixes a data corruption in smb_proc_setattr_unix()
(smb_filetype_from_mode() returns an u32, and there are only four bytes
reserved for it in data.

Signed-off-by: Adrian Bunk <bunk@stusta.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
  • Loading branch information
Maciej W. Rozycki authored and Linus Torvalds committed Jan 9, 2006
1 parent a12dea7 commit ac34dd0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion fs/smbfs/proc.c
Original file line number Diff line number Diff line change
Expand Up @@ -3113,7 +3113,7 @@ smb_proc_setattr_unix(struct dentry *d, struct iattr *attr,
LSET(data, 32, SMB_TIME_NO_CHANGE);
LSET(data, 40, SMB_UID_NO_CHANGE);
LSET(data, 48, SMB_GID_NO_CHANGE);
LSET(data, 56, smb_filetype_from_mode(attr->ia_mode));
DSET(data, 56, smb_filetype_from_mode(attr->ia_mode));
LSET(data, 60, major);
LSET(data, 68, minor);
LSET(data, 76, 0);
Expand Down

0 comments on commit ac34dd0

Please sign in to comment.