diff options
author | Jun-ichiro itojun Hagino <itojun@cvs.openbsd.org> | 2002-06-30 13:04:37 +0000 |
---|---|---|
committer | Jun-ichiro itojun Hagino <itojun@cvs.openbsd.org> | 2002-06-30 13:04:37 +0000 |
commit | 4239d6781953c558ebf4fa2010ff23f4630ad217 (patch) | |
tree | d710661406931ea40c38847efa1b70a1495afa74 /sys/net/if_enc.c | |
parent | fd0bfbacd2b21eb3bf2543307b763fe112b060aa (diff) |
allocate sockaddr_dl for ifnet in if_alloc_sadl(), as we don't always know
the size of sockaddr_dl on if_attach() - for instance, see ether_ifattach().
from netbsd. fgs ok
Diffstat (limited to 'sys/net/if_enc.c')
-rw-r--r-- | sys/net/if_enc.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sys/net/if_enc.c b/sys/net/if_enc.c index 9385d95ea85..8411f35eff5 100644 --- a/sys/net/if_enc.c +++ b/sys/net/if_enc.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_enc.c,v 1.38 2002/05/29 07:54:58 itojun Exp $ */ +/* $OpenBSD: if_enc.c,v 1.39 2002/06/30 13:04:36 itojun Exp $ */ /* * The authors of this code are John Ioannidis (ji@tla.org), * Angelos D. Keromytis (kermit@csd.uch.gr) and @@ -111,6 +111,7 @@ encattach(int nenc) ifp->if_snd.ifq_maxlen = ifqmaxlen; ifp->if_hdrlen = ENC_HDRLEN; if_attach(ifp); + if_alloc_sadl(ifp); #if NBPFILTER > 0 bpfattach(&encif[i].sc_if.if_bpf, ifp, DLT_ENC, ENC_HDRLEN); |