diff options
author | Miklos Szeredi <mszeredi@suse.cz> | 2013-10-10 16:48:19 +0200 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2013-10-15 18:14:06 +0200 |
commit | 43ae9e3fc70ca0057ae0a24ef5eedff05e3fae06 (patch) | |
tree | c90e593024fa7d4d3e7ce375e94110ef73d0a66a /fs/ext3 | |
parent | Merge tag 'pm+acpi-3.12-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git... (diff) | |
download | linux-43ae9e3fc70ca0057ae0a24ef5eedff05e3fae06.tar.xz linux-43ae9e3fc70ca0057ae0a24ef5eedff05e3fae06.zip |
ext[34]: fix double put in tmpfile
d_tmpfile() already swallowed the inode ref.
Signed-off-by: Miklos Szeredi <mszeredi@suse.cz>
Cc: stable@vger.kernel.org
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs/ext3')
-rw-r--r-- | fs/ext3/namei.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/fs/ext3/namei.c b/fs/ext3/namei.c index 1194b1f0f839..f8cde46de9cd 100644 --- a/fs/ext3/namei.c +++ b/fs/ext3/namei.c @@ -1783,7 +1783,7 @@ retry: d_tmpfile(dentry, inode); err = ext3_orphan_add(handle, inode); if (err) - goto err_drop_inode; + goto err_unlock_inode; mark_inode_dirty(inode); unlock_new_inode(inode); } @@ -1791,10 +1791,9 @@ retry: if (err == -ENOSPC && ext3_should_retry_alloc(dir->i_sb, &retries)) goto retry; return err; -err_drop_inode: +err_unlock_inode: ext3_journal_stop(handle); unlock_new_inode(inode); - iput(inode); return err; } |