[PATCH 43/48] xfs_repair: drop buffer reference on symlink error

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Dave Chinner <dchinner@xxxxxxxxxx>

Failing to drop the buffer when the header is bad results in a
deadlock in a later phase when we try to read the remote symlink
again.

Signed-off-by: Dave Chinner <dchinner@xxxxxxxxxx>
---
 repair/dinode.c |    1 +
 1 file changed, 1 insertion(+)

diff --git a/repair/dinode.c b/repair/dinode.c
index 2df9a91..31a26d7 100644
--- a/repair/dinode.c
+++ b/repair/dinode.c
@@ -1523,6 +1523,7 @@ _("cannot read inode %" PRIu64 ", file block %d, disk block %" PRIu64 "\n"),
 					do_warn(
 _("bad symlink header ino %" PRIu64 ", file block %d, disk block %" PRIu64 "\n"),
 						lino, i, fsbno);
+					libxfs_putbuf(bp);
 					return(1);
 				}
 				buf_data += sizeof(struct xfs_dsymlink_hdr);
-- 
1.7.10.4

_______________________________________________
xfs mailing list
xfs@xxxxxxxxxxx
http://oss.sgi.com/mailman/listinfo/xfs




[Index of Archives]     [Linux XFS Devel]     [Linux Filesystem Development]     [Filesystem Testing]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux