diff options
author | rwatson <rwatson@FreeBSD.org> | 2004-03-09 23:55:59 +0000 |
---|---|---|
committer | rwatson <rwatson@FreeBSD.org> | 2004-03-09 23:55:59 +0000 |
commit | b6f84aeea90f96aed6fe4178ed63b04761e32614 (patch) | |
tree | 790d517bf895f7ebe98317b49c993cfca225e56f | |
parent | ae10eb519899f2d5966b32c4427598182dae0862 (diff) | |
download | FreeBSD-src-b6f84aeea90f96aed6fe4178ed63b04761e32614.zip FreeBSD-src-b6f84aeea90f96aed6fe4178ed63b04761e32614.tar.gz |
Const-poison ethernet and FDDI broadcast address constants, as they
are accessed read-only.
-rw-r--r-- | sys/net/if_ethersubr.c | 2 | ||||
-rw-r--r-- | sys/net/if_fddisubr.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/sys/net/if_ethersubr.c b/sys/net/if_ethersubr.c index aced961..2bffbaf 100644 --- a/sys/net/if_ethersubr.c +++ b/sys/net/if_ethersubr.c @@ -111,7 +111,7 @@ bdg_forward_t *bdg_forward_ptr; bdgtakeifaces_t *bdgtakeifaces_ptr; struct bdg_softc *ifp2sc; -static u_char etherbroadcastaddr[ETHER_ADDR_LEN] = +static const u_char etherbroadcastaddr[ETHER_ADDR_LEN] = { 0xff, 0xff, 0xff, 0xff, 0xff, 0xff }; static int ether_resolvemulti(struct ifnet *, struct sockaddr **, diff --git a/sys/net/if_fddisubr.c b/sys/net/if_fddisubr.c index b7f07db..e6c1920 100644 --- a/sys/net/if_fddisubr.c +++ b/sys/net/if_fddisubr.c @@ -89,7 +89,7 @@ extern u_char at_org_code[ 3 ]; extern u_char aarp_org_code[ 3 ]; #endif /* NETATALK */ -static u_char fddibroadcastaddr[FDDI_ADDR_LEN] = +static const u_char fddibroadcastaddr[FDDI_ADDR_LEN] = { 0xff, 0xff, 0xff, 0xff, 0xff, 0xff }; static int fddi_resolvemulti(struct ifnet *, struct sockaddr **, |