Fix error message to print the depth of a corrupt htree directory.
Signed-off-by: Andreas Dilger <adilger@sun.com>
Signed-off-by: Kalpak Shah <kalpak.shah@sun.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
if (dx_db->type == DX_DIRBLOCK_LEAF) {
depth = htree_depth(dx_dir, dx_db);
if (depth != dx_dir->depth) {
+ pctx.num = dx_dir->depth;
code = PR_2_HTREE_BAD_DEPTH;
fix_problem(ctx, code, &pctx);
bad_dir++;
/* Node in HTREE directory has invalid depth */
{ PR_2_HTREE_BAD_DEPTH,
- N_("@p @h %d: node (%B) has @n depth\n"),
+ N_("@p @h %d: node (%B) has @n depth (%N)\n"),
PROMPT_NONE, 0 },
/* Duplicate directory entry found */
Problem in HTREE directory inode 12929: node (531) has bad max hash
Problem in HTREE directory inode 12929: node (993) referenced twice
Problem in HTREE directory inode 12929: node (1061) has bad min hash
-Problem in HTREE directory inode 12929: node (1062) has invalid depth
+Problem in HTREE directory inode 12929: node (1062) has invalid depth (2)
Problem in HTREE directory inode 12929: node (1062) has bad max hash
Problem in HTREE directory inode 12929: node (1062) not referenced
Invalid HTREE directory inode 12929 (/test2). Clear HTree index? yes