3
0
mirror of https://git.kernel.org/pub/scm/network/wireless/iwd.git synced 2024-11-16 17:09:24 +01:00

client: use display_table_row for IPv6 in station

IPv6 address entry was not updated to use display_table_row which led to
a shifted line in table, as shown below:

    $ iwctl station wlan0 show | head | sed 's| |.|g'
    .................................Station:.wlan0................................
    --------------------------------------------------------------------------------
    ..Settable..Property..............Value..........................................
    --------------------------------------------------------------------------------
    ............Scanning..............no...............................................
    ............State.................connected........................................
    ............Connected.network.....Clannad.Legacy...................................
    ............IPv4.address..........192.168.1.12.....................................
    ............IPv6.address........fdc3:541d:864f:0:96db:c9ff:fe36:b15............
    ............ConnectedBss..........cc:d8:43:77:91:0e................................

This patch aligns IPv6 address line with other lines in the table.

Fixes: 35dd2c0821 (client: update station to use display_table_row, 2022-07-07)
This commit is contained in:
Yuki Sireneva 2024-07-23 19:18:17 +03:00 committed by Denis Kenzior
parent 06c8080664
commit 91f7253ae1

View File

@ -175,8 +175,8 @@ static void display_addresses(const char *device_name)
continue; continue;
have_address = true; have_address = true;
display("%s%*s %-*s%-*s\n", MARGIN, 8, "", 20, display_table_row(MARGIN, 3, 8, "", 20,
"IPv6 address", 47, addrstr); "IPv6 address", 47, addrstr);
} else if (cur->ifa_addr->sa_family == AF_INET) { } else if (cur->ifa_addr->sa_family == AF_INET) {
struct sockaddr_in *si = struct sockaddr_in *si =
(struct sockaddr_in *) cur->ifa_addr; (struct sockaddr_in *) cur->ifa_addr;