diff options
Diffstat (limited to 'fs')
-rw-r--r-- | fs/ext2/inode.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/ext2/inode.c b/fs/ext2/inode.c index 19214435b75..3675088cb88 100644 --- a/fs/ext2/inode.c +++ b/fs/ext2/inode.c @@ -1552,7 +1552,7 @@ int ext2_setattr(struct dentry *dentry, struct iattr *iattr) if (error) return error; } - if (iattr->ia_valid & ATTR_SIZE) { + if (iattr->ia_valid & ATTR_SIZE && iattr->ia_size != inode->i_size) { error = ext2_setsize(inode, iattr->ia_size); if (error) return error; |