sbin/hammer: fix counter-intuitive output of hammer show command
authorTomohiro Kusumi <kusumi.tomohiro@gmail.com>
Tue, 30 Dec 2014 23:16:28 +0000 (08:16 +0900)
committerAntonio Huete Jimenez <tuxillo@quantumachine.net>
Sat, 17 Jan 2015 16:01:55 +0000 (17:01 +0100)
- Change 'hammer show' ELM output to match the comparison order in the
  RB tree cmp functions.

Closes: #2755

sbin/hammer/cmd_show.c

index 4d69e36..7a8aa92 100644 (file)
@@ -261,11 +261,11 @@ print_btree_elm(hammer_btree_elm_t elm, int i, u_int8_t type,
        printf("%s\t%s %2d %c ",
               flagstr, label, i,
               (elm->base.btype ? elm->base.btype : '?'));
-       printf("obj=%016jx key=%016jx lo=%08x rt=%02x ot=%02x\n",
-              (uintmax_t)elm->base.obj_id,
-              (uintmax_t)elm->base.key,
+       printf("lo=%08x obj=%016jx rt=%02x key=%016jx ot=%02x\n",
               elm->base.localization,
+              (uintmax_t)elm->base.obj_id,
               elm->base.rec_type,
+              (uintmax_t)elm->base.key,
               elm->base.obj_type);
        printf("\t       %c tids %016jx:%016jx ",
                (elm->base.delete_tid ? 'd' : ' '),