Don't announce the ethernet address when it's 00:00:00:00:00:00. It's
not of any interest. This primairly happens when vlan(4) interfaces are created.
This commit is contained in:
parent
3ad94a6543
commit
5ac5094b81
@ -847,6 +847,7 @@ ether_sprintf(const u_char *ap)
|
|||||||
void
|
void
|
||||||
ether_ifattach(struct ifnet *ifp, const u_int8_t *llc)
|
ether_ifattach(struct ifnet *ifp, const u_int8_t *llc)
|
||||||
{
|
{
|
||||||
|
int i;
|
||||||
struct ifaddr *ifa;
|
struct ifaddr *ifa;
|
||||||
struct sockaddr_dl *sdl;
|
struct sockaddr_dl *sdl;
|
||||||
|
|
||||||
@ -881,8 +882,12 @@ ether_ifattach(struct ifnet *ifp, const u_int8_t *llc)
|
|||||||
if (BDG_LOADED)
|
if (BDG_LOADED)
|
||||||
bdgtakeifaces_ptr();
|
bdgtakeifaces_ptr();
|
||||||
|
|
||||||
/* Announce Ethernet MAC address. */
|
/* Announce Ethernet MAC address if non-zero. */
|
||||||
if_printf(ifp, "Ethernet address: %6D\n", llc, ":");
|
for (i = 0; i < ifp->if_addrlen; i++)
|
||||||
|
if (llc[i] != 0)
|
||||||
|
break;
|
||||||
|
if (i != ifp->if_addrlen)
|
||||||
|
if_printf(ifp, "Ethernet address: %6D\n", llc, ":");
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
Loading…
Reference in New Issue
Block a user