Message ID | 1265832009-8070-1-git-send-email-jslaby@suse.cz (mailing list archive) |
---|---|
State | Accepted |
Headers | show |
diff --git a/fs/btrfs/inode.c b/fs/btrfs/inode.c index c41db6d..5aa0cef 100644 --- a/fs/btrfs/inode.c +++ b/fs/btrfs/inode.c @@ -3256,8 +3256,7 @@ static int btrfs_setattr_size(struct inode *inode, struct iattr *attr) return 0; if (attr->ia_size > inode->i_size) { - unsigned long limit; - limit = current->signal->rlim[RLIMIT_FSIZE].rlim_cur; + unsigned long limit = rlimit(RLIMIT_FSIZE); if (attr->ia_size > inode->i_sb->s_maxbytes) return -EFBIG; if (limit != RLIM_INFINITY && attr->ia_size > limit) {