From: Dhruvesh Rathore Date: Wed, 11 Feb 2015 00:14:24 +0000 (+1100) Subject: spaceman: Add table header for -d option X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=refs%2Fheads%2Fspaceman;p=users%2Fhch%2Fxfsprogs.git spaceman: Add table header for -d option The xfs_spaceman utility did not have a a proper title to the content displayed using -d (debug) option. Old output: $ sudo xfs_spaceman -c "freesp -d" /media/xfs 0 4 1 0 5 1 0 6 1 0 7 1 ..... This patch adds a suitable title header to the output, making it much more readable to the user. New output: $ sudo xfs_spaceman -c "freesp -d" /media/xfs agno agbno len 0 4 1 0 5 1 0 6 1 0 7 1 .... Signed-off-by: Dhruvesh Rathore Signed-off-by: Amey Ruikar Signed-off-by: Somdeep Dey --- diff --git a/spaceman/freesp.c b/spaceman/freesp.c index b5b353da2..835c50439 100644 --- a/spaceman/freesp.c +++ b/spaceman/freesp.c @@ -327,6 +327,10 @@ freesp_f( if (!init(argc, argv)) return 0; + + if (dumpflag) + printf("%8s %8s %8s\n", "agno", "agbno", "len"); + for (agno = 0; agno < file->geom.agcount; agno++) { if (inaglist(agno)) scan_ag(agno);