lkml.org 
[lkml]   [2013]   [Nov]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [patch] fat: double unlock on error path
Date
Dan Carpenter <dan.carpenter@oracle.com> writes:

> There is a stray unlock here which was not intended. I have removed it.
>
> Fixes: 3f9f3dfb5755 ('fat: add fat_fallocate operation')
> Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
>
> diff --git a/fs/fat/file.c b/fs/fat/file.c
> index 03f716f..befedee 100644
> --- a/fs/fat/file.c
> +++ b/fs/fat/file.c
> @@ -257,10 +257,8 @@ static long fat_fallocate(struct file *file, int mode,
> goto error;
>
> err = inode_newsize_ok(inode, (len + offset));
> - if (err) {
> - mutex_unlock(&inode->i_mutex);
> + if (err)
> goto error;
> - }
>
> if (mode & FALLOC_FL_KEEP_SIZE) {
> /* First compute the number of clusters to be allocated */

Right. Namjae, please include this fix to patchset at next time.

Thanks.
--
OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>


\
 
 \ /
  Last update: 2013-11-08 06:21    [W:0.027 / U:0.308 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site