diff options
author | Jonathan Gray <jsg@cvs.openbsd.org> | 2015-04-22 04:12:23 +0000 |
---|---|---|
committer | Jonathan Gray <jsg@cvs.openbsd.org> | 2015-04-22 04:12:23 +0000 |
commit | 88a9c664c9bdc4ad1de61246f1d15457d58360b9 (patch) | |
tree | f8ee11c8ed8867d62f52cc63a2bc33f207ad941e /sys | |
parent | b52875f8db6584275a1d1c4077ea0dbe2bc9f2ef (diff) |
Init rt to NULL in arpresolve(). Not a problem in practice
as la will be NULL when rt is uninitialised which should cause
the function to return, but makes the code easier to follow.
ok mpi@ miod@
Diffstat (limited to 'sys')
-rw-r--r-- | sys/netinet/if_ether.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/netinet/if_ether.c b/sys/netinet/if_ether.c index 43a88e8843e..b7e582e009a 100644 --- a/sys/netinet/if_ether.c +++ b/sys/netinet/if_ether.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_ether.c,v 1.150 2015/04/10 13:58:20 dlg Exp $ */ +/* $OpenBSD: if_ether.c,v 1.151 2015/04/22 04:12:22 jsg Exp $ */ /* $NetBSD: if_ether.c,v 1.31 1996/05/11 12:59:58 mycroft Exp $ */ /* @@ -357,7 +357,7 @@ arpresolve(struct arpcom *ac, struct rtentry *rt0, struct mbuf *m, { struct llinfo_arp *la; struct sockaddr_dl *sdl; - struct rtentry *rt; + struct rtentry *rt = NULL; struct mbuf *mh; char addr[INET_ADDRSTRLEN]; int error; |