git: d98981585c9a - main - ether_resolve_addr: eh is only used for INET or INET6.
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Wed, 13 Apr 2022 23:09:32 UTC
The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=d98981585c9a4de8105979d59d38ab6b4ce294c3 commit d98981585c9a4de8105979d59d38ab6b4ce294c3 Author: John Baldwin <jhb@FreeBSD.org> AuthorDate: 2022-04-13 23:08:21 +0000 Commit: John Baldwin <jhb@FreeBSD.org> CommitDate: 2022-04-13 23:08:21 +0000 ether_resolve_addr: eh is only used for INET or INET6. --- sys/net/if_ethersubr.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/sys/net/if_ethersubr.c b/sys/net/if_ethersubr.c index 0427e1352ab1..d92c49b6f39c 100644 --- a/sys/net/if_ethersubr.c +++ b/sys/net/if_ethersubr.c @@ -202,16 +202,15 @@ ether_resolve_addr(struct ifnet *ifp, struct mbuf *m, const struct sockaddr *dst, struct route *ro, u_char *phdr, uint32_t *pflags, struct llentry **plle) { - struct ether_header *eh; uint32_t lleflags = 0; int error = 0; #if defined(INET) || defined(INET6) + struct ether_header *eh = (struct ether_header *)phdr; uint16_t etype; #endif if (plle) *plle = NULL; - eh = (struct ether_header *)phdr; switch (dst->sa_family) { #ifdef INET