diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2020-06-13 12:40:24 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2020-06-13 12:40:24 -0700 |
commit | c55572276834f8b17c859db7d20c224fe25b9eda (patch) | |
tree | 91644a9b3d64a7b1d3b0dfa60f808b14e164d8c3 | |
parent | 61f3e825bec7364790cb7d193a9a156c46119cff (diff) | |
parent | 8cc0072469723459dc6bd7beff81b2b3149f4cf4 (diff) |
Merge tag 'xfs-5.8-merge-9' of git://git.kernel.org/pub/scm/fs/xfs/xfs-linux
Pull xfs fix from Darrick Wong:
"We've settled down into the bugfix phase; this one fixes a resource
leak on an error bailout path"
* tag 'xfs-5.8-merge-9' of git://git.kernel.org/pub/scm/fs/xfs/xfs-linux:
xfs: Add the missed xfs_perag_put() for xfs_ifree_cluster()
-rw-r--r-- | fs/xfs/xfs_inode.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/fs/xfs/xfs_inode.c b/fs/xfs/xfs_inode.c index 4c91fb25ec66..9aea7d68d8ab 100644 --- a/fs/xfs/xfs_inode.c +++ b/fs/xfs/xfs_inode.c @@ -2634,8 +2634,10 @@ xfs_ifree_cluster( error = xfs_trans_get_buf(tp, mp->m_ddev_targp, blkno, mp->m_bsize * igeo->blocks_per_cluster, XBF_UNMAPPED, &bp); - if (error) + if (error) { + xfs_perag_put(pag); return error; + } /* * This buffer may not have been correctly initialised as we |