]> git.baikalelectronics.ru Git - kernel.git/commit
fs/affs: release old buffer head on error path
authorPan Bian <bianpan2016@163.com>
Wed, 20 Jan 2021 08:51:13 +0000 (00:51 -0800)
committerDavid Sterba <dsterba@suse.com>
Tue, 9 Feb 2021 16:11:03 +0000 (17:11 +0100)
commit4ce39a1a45fcdafdba3eb6aef2e43841281fa290
treedab88538affbb32feea48a17ae911ba1e78ead98
parentb282607df7668b74dacffe3bae2cf79eff9921b8
fs/affs: release old buffer head on error path

The reference count of the old buffer head should be decremented on path
that fails to get the new buffer head.

Fixes: 6ec7b15363dd ("fs/affs: add rename exchange")
CC: stable@vger.kernel.org # 4.14+
Signed-off-by: Pan Bian <bianpan2016@163.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/affs/namei.c