From f34111d1bd31511b8d28ead61a74abf70692ac69 Mon Sep 17 00:00:00 2001 From: Bartosz Golaszewski Date: Sat, 28 Jan 2017 17:00:46 +0100 Subject: [PATCH] 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 --- src/tools/gpioinfo.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) 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) -- 2.30.2