← Commit list

db169f253

Denys Vlasenko
Denys Vlasenko
2018-03-08
SUCCESS Duration: 144s

Subject

ip: fix "ip -oneline a"

Binary

No binary (build failed)

Architecture & Compiler Flags

Architecture: x86_64-linux-gnu Compiler: gcc (Ubuntu 11.4.0-1ubuntu1~22.04.3) 11.4.0

—

Build Log

(log yok)

Commit Diff GitHub →

networking/libiproute/ipaddress.c+4 -1
@@ -570,7 +570,10 @@ int FAST_FUNC ipaddr_list_or_flush(char **argv, int flush)
}
for (l = linfo; l; l = l->next) {
- if (no_link || print_linkinfo(&l->h) == 0) {
+ if (no_link
+ || (oneline || print_linkinfo(&l->h) == 0)
+ /* ^^^^^^^^^ "ip -oneline a" does not print link info */
+ ) {
struct ifinfomsg *ifi = NLMSG_DATA(&l->h);
if (G_filter.family != AF_PACKET)
print_selected_addrinfo(ifi->ifi_index, ainfo);