iproute2: Format IPv6 tunnels endpoints nicely.
Change formatting of IPv6 tunnel endpoints from hex chain to standard IPv6 representation. Signed-off-by: David Lamparter <equinox@diac24.net> Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
This commit is contained in:
parent
bdf9e86d72
commit
0280ef85aa
|
|
@ -38,6 +38,9 @@ const char *ll_addr_n2a(unsigned char *addr, int alen, int type, char *buf, int
|
||||||
(type == ARPHRD_TUNNEL || type == ARPHRD_SIT || type == ARPHRD_IPGRE)) {
|
(type == ARPHRD_TUNNEL || type == ARPHRD_SIT || type == ARPHRD_IPGRE)) {
|
||||||
return inet_ntop(AF_INET, addr, buf, blen);
|
return inet_ntop(AF_INET, addr, buf, blen);
|
||||||
}
|
}
|
||||||
|
if (alen == 16 && type == ARPHRD_TUNNEL6) {
|
||||||
|
return inet_ntop(AF_INET6, addr, buf, blen);
|
||||||
|
}
|
||||||
l = 0;
|
l = 0;
|
||||||
for (i=0; i<alen; i++) {
|
for (i=0; i<alen; i++) {
|
||||||
if (i==0) {
|
if (i==0) {
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue