scoutfs-utils: clean up 'stat' output

The previous formatting was modeled after the free form 'stat' output
and it's a real mess.  Just make it a simple "name value" table.

Signed-off-by: Zach Brown <zab@versity.com>
This commit is contained in:
Zach Brown
2018-02-14 11:35:49 -08:00
committed by Zach Brown
parent 2527b4906e
commit 02204c36fc

View File

@@ -47,13 +47,17 @@ static int stat_more_cmd(int argc, char **argv)
fprintf(stderr, "stat_more ioctl failed on '%s': "
"%s (%d)\n", path, strerror(errno), errno);
} else {
printf(" File: '%s'\n"
" meta_seq: %-20llu data_seq %-20llu"
" data_version: %-20llu\n"
" online_blocks: %-20llu "
" offline_blocks: %-20llu\n",
path, stm.meta_seq, stm.data_seq,
stm.data_version, stm.online_blocks,
printf("path %s\n"
"meta_seq %llu\n"
"data_seq %llu\n"
"data_version %llu\n"
"online_blocks %llu\n"
"offline_blocks %llu\n",
path,
stm.meta_seq,
stm.data_seq,
stm.data_version,
stm.online_blocks,
stm.offline_blocks);
}