Home Home > GIT Browse > stable-xen
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEvgeniy Polyakov <johnpol@2ka.mipt.ru>2006-01-03 17:59:19 -0800
committerChris Wright <chrisw@sous-sol.org>2006-01-07 18:15:09 -0800
commita8c6aa8791db53edbe27e6a4ae57ef95fc2c01c6 (patch)
treebcb874f0b779e97477932afccef14e77eb89bd5a
parent002cf2a8adbb7b9d9911f410e2db78c7a3798d14 (diff)
[PATCH] UFS: inode->i_sem is not released in error path
Signed-off-by: Evgeniy Polyakov <johnpol@2ka.mipt.ru> Cc: <stable@kernel.org> akpm: obviously correct, OK for -stable immediately. Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Chris Wright <chrisw@sous-sol.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-rw-r--r--fs/ufs/super.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/fs/ufs/super.c b/fs/ufs/super.c
index f036d694ba5a..b4662651d63d 100644
--- a/fs/ufs/super.c
+++ b/fs/ufs/super.c
@@ -1294,8 +1294,10 @@ static ssize_t ufs_quota_write(struct super_block *sb, int type,
blk++;
}
out:
- if (len == towrite)
+ if (len == towrite) {
+ up(&inode->i_sem);
return err;
+ }
if (inode->i_size < off+len-towrite)
i_size_write(inode, off+len-towrite);
inode->i_version++;