From: Heiko Carstens Date: Tue, 6 Sep 2011 00:52:53 +0000 (+0200) Subject: lscpu: fix cache output for extended parsable output X-Git-Tag: v2.21-rc1~453 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=08cd09415ade0956484170fc6e0d7b22677dcbd1;p=thirdparty%2Futil-linux.git lscpu: fix cache output for extended parsable output The extended parsable output prints a colon instead of comma between each item. The case where a CPU doesn't belong to any cache was not converted. Just fix this. Signed-off-by: Heiko Carstens --- diff --git a/sys-utils/lscpu.c b/sys-utils/lscpu.c index f6641463f1..f231e0e0e5 100644 --- a/sys-utils/lscpu.c +++ b/sys-utils/lscpu.c @@ -922,7 +922,7 @@ print_parsable_cell(struct lscpu_desc *desc, int i, int col, int compatible) } } if (x == ca->nsharedmaps) - putchar(','); + putchar(compatible ? ',' : ':'); } break; case COL_POLARIZATION: