mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-05-06 01:09:54 +02:00
cli: don't print how many more addresses/routes in nmcli output
Since the number of addresses/routes that the daemon exposes on D-Bus is now limited, we don't know how many more there would be. Just say "more".
This commit is contained in:
parent
4bb3ad0977
commit
a2cd6599d2
1 changed files with 3 additions and 3 deletions
|
|
@ -1458,8 +1458,8 @@ ac_overview(NmCli *nmc, NMActiveConnection *ac)
|
||||||
/* Print always at least MAX_ADDRESSES fully.
|
/* Print always at least MAX_ADDRESSES fully.
|
||||||
* If there are MAX_ADDRESSES+1 addresses, print them all fully.
|
* If there are MAX_ADDRESSES+1 addresses, print them all fully.
|
||||||
* If there are more addresses, print MAX_ADDRESSES fully, and a
|
* If there are more addresses, print MAX_ADDRESSES fully, and a
|
||||||
* "N more" line. */
|
* "more" line. */
|
||||||
nmc_print("\tinet%c ... %u more\n", IS_IPv4 ? '4' : '6', p->len - i - 1u);
|
nmc_print("\tinet%c ... more\n", IS_IPv4 ? '4' : '6');
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -1474,7 +1474,7 @@ ac_overview(NmCli *nmc, NMActiveConnection *ac)
|
||||||
nmc_print("\troute%c %s\n", IS_IPv4 ? '4' : '6', nm_str_buf_get_str(&str));
|
nmc_print("\troute%c %s\n", IS_IPv4 ? '4' : '6', nm_str_buf_get_str(&str));
|
||||||
|
|
||||||
if (i >= MAX_ROUTES - 1u && p->len - i > 2u) {
|
if (i >= MAX_ROUTES - 1u && p->len - i > 2u) {
|
||||||
nmc_print("\troute%c ... %u more\n", IS_IPv4 ? '4' : '6', p->len - i - 1u);
|
nmc_print("\troute%c ... more\n", IS_IPv4 ? '4' : '6');
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue