Skip to content

Commit

Permalink
[PATCH] quota: fix possible oops on quotaoff
Browse files Browse the repository at this point in the history
Remove dquot structures from quota file on quotaon - quota code does not
expect them to be there.

Signed-off-by: Jan Kara <jack@suse.cz>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
  • Loading branch information
jankara authored and Linus Torvalds committed Apr 16, 2005
1 parent e072c6f commit 31e7ad6
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions fs/dquot.c
Original file line number Diff line number Diff line change
Expand Up @@ -1443,6 +1443,7 @@ static int vfs_quota_on_inode(struct inode *inode, int type, int format_id)
oldflags = inode->i_flags & (S_NOATIME | S_IMMUTABLE | S_NOQUOTA);
inode->i_flags |= S_NOQUOTA | S_NOATIME | S_IMMUTABLE;
up_write(&dqopt->dqptr_sem);
sb->dq_op->drop(inode);

error = -EIO;
dqopt->files[type] = igrab(inode);
Expand Down

0 comments on commit 31e7ad6

Please sign in to comment.