From: Bartosz Golaszewski Date: Sat, 28 Jan 2017 16:00:46 +0000 (+0100) Subject: gpioinfo: increase the width of the line offset X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=f34111d1bd31511b8d28ead61a74abf70692ac69;p=qemu-gpiodev%2Flibgpiod.git gpioinfo: increase the width of the line offset Increase the width of the line offset to 3 - that way we can display 999 lines before the formatting will be shifted. This should be generally enough, but we should still implement a correct, generic solution for gpioinfo display. Signed-off-by: Bartosz Golaszewski --- diff --git a/src/tools/gpioinfo.c b/src/tools/gpioinfo.c index d09f78f..e9a9de1 100644 --- a/src/tools/gpioinfo.c +++ b/src/tools/gpioinfo.c @@ -113,7 +113,7 @@ static void list_lines(struct gpiod_chip *chip) of = false; printf("\tline "); - prinfo(&of, 2, "%u", offset); + prinfo(&of, 3, "%u", offset); printf(": "); name ? prinfo(&of, 12, "\"%s\"", name)