xfs
[Top] [All Lists]

[PATCH 22/21] xfs: Fix magic number assert in xfs_dir3_leaf_log_bests

To: xfs@xxxxxxxxxxx
Subject: [PATCH 22/21] xfs: Fix magic number assert in xfs_dir3_leaf_log_bests
From: Dave Chinner <david@xxxxxxxxxxxxx>
Date: Tue, 12 Mar 2013 23:43:31 +1100
Delivered-to: xfs@xxxxxxxxxxx
In-reply-to: <1363091454-8852-1-git-send-email-david@xxxxxxxxxxxxx>
References: <1363091454-8852-1-git-send-email-david@xxxxxxxxxxxxx>
User-agent: Mutt/1.5.21 (2010-09-15)
From: Dave Chinner <dchinner@xxxxxxxxxx>

Make sure we set the magic number correctly when converting
from node to leaf form.

Signed-off-by: Dave Chinner <dchinner@xxxxxxxxxx>
---

This should probably be folded into patch 14/21. I missed this hunk
when bringing it forward to 3.9-rc2 and folding all the bugs fixes
I had in debug patches back into their original patches.

 fs/xfs/xfs_dir2_leaf.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/fs/xfs/xfs_dir2_leaf.c b/fs/xfs/xfs_dir2_leaf.c
index 015c078..43a5c8543c4 100644
--- a/fs/xfs/xfs_dir2_leaf.c
+++ b/fs/xfs/xfs_dir2_leaf.c
@@ -2199,7 +2199,7 @@ xfs_dir2_node_to_leaf(
        xfs_trans_buf_set_type(tp, lbp, XFS_BLF_DIR_LEAF1_BUF);
        leafhdr.magic = (leafhdr.magic == XFS_DIR2_LEAFN_MAGIC)
                                        ? XFS_DIR2_LEAF1_MAGIC
-                                       : XFS_DIR3_LEAFN_MAGIC;
+                                       : XFS_DIR3_LEAF1_MAGIC;
 
        /*
         * Set up the leaf tail from the freespace block.

<Prev in Thread] Current Thread [Next in Thread>