From: Todd Zullinger Date: Tue, 18 Jul 2023 03:16:00 +0000 (-0400) Subject: lastlog: fix alignment of Latest header X-Git-Tag: 4.14.0-rc1~19 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2643f27b360d44dcb5514072316eb112a867904e;p=thirdparty%2Fshadow.git lastlog: fix alignment of Latest header b1282224 (Add maximum padding to fit IPv6-Addresses, 2020-05-24) pads the From field header using `maxIPv6Addrlen - 3`. This leaves the Latest field header misaligned. Subtract 4 (the length of "From"). --- diff --git a/src/lastlog.c b/src/lastlog.c index 6b9619740..1db668871 100644 --- a/src/lastlog.c +++ b/src/lastlog.c @@ -143,7 +143,7 @@ static void print_one (/*@null@*/const struct passwd *pw) /* Print the header only once */ if (!once) { #ifdef HAVE_LL_HOST - printf (_("Username Port From%*sLatest\n"), maxIPv6Addrlen-3, " "); + printf (_("Username Port From%*sLatest\n"), maxIPv6Addrlen-4, " "); #else puts (_("Username Port Latest")); #endif