diff mbox series

[33/36] libxfs: don't touch buffer log item pointer when flushing inode log item

Message ID 155259763568.31886.8011442389519021944.stgit@magnolia (mailing list archive)
State Superseded, archived
Headers show
Series xfsprogs-5.0: fix various problems | expand

Commit Message

Darrick J. Wong March 14, 2019, 9:07 p.m. UTC
From: Darrick J. Wong <darrick.wong@oracle.com>

When we're flushing an inode log item, it is not necessary to mess with
the inode cluster buffer's log item because the iflush code paths pass
the inode log item directly.  The unconditional reset causes us to leak
buffer log items.

Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
---
 libxfs/trans.c |    2 --
 1 file changed, 2 deletions(-)
diff mbox series

Patch

diff --git a/libxfs/trans.c b/libxfs/trans.c
index 295e687e..bd7bbc69 100644
--- a/libxfs/trans.c
+++ b/libxfs/trans.c
@@ -861,10 +861,8 @@  inode_item_done(
 	 * of whether the flush succeed or not. If we fail the flush, make sure
 	 * we still release the buffer reference we currently hold.
 	 */
-	bp->b_log_item = iip;
 	error = libxfs_iflush_int(ip, bp);
 	ip->i_transp = NULL;	/* disassociate from transaction */
-	bp->b_log_item = NULL;	/* remove log item */
 	bp->b_transp = NULL;	/* remove xact ptr */
 
 	if (error) {