diff options
author | kmacy <kmacy@FreeBSD.org> | 2008-12-24 05:31:26 +0000 |
---|---|---|
committer | kmacy <kmacy@FreeBSD.org> | 2008-12-24 05:31:26 +0000 |
commit | bc73e3c3699aa8edb5614c8213055b475c6b2fb2 (patch) | |
tree | 399026429b05ea0ae11caeba5b3e316b5423c9f5 /sys | |
parent | 0a4722ed76cf251d1ac9283135ec7b01c5384ab5 (diff) | |
download | FreeBSD-src-bc73e3c3699aa8edb5614c8213055b475c6b2fb2.zip FreeBSD-src-bc73e3c3699aa8edb5614c8213055b475c6b2fb2.tar.gz |
Fix missed unlock and reference drop of lle
Found by: pho
Diffstat (limited to 'sys')
-rw-r--r-- | sys/netinet/if_ether.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/sys/netinet/if_ether.c b/sys/netinet/if_ether.c index 31a13c9..4e7086a 100644 --- a/sys/netinet/if_ether.c +++ b/sys/netinet/if_ether.c @@ -156,12 +156,12 @@ arptimer(void *arg) ifp = lle->lle_tbl->llt_ifp; IF_AFDATA_LOCK(ifp); LLE_WLOCK(lle); - if ((lle->la_flags & LLE_DELETED) || - (time_second >= lle->la_expire)) { - if (!callout_pending(&lle->la_timer) && - callout_active(&lle->la_timer)) - (void) llentry_free(lle); - } else { + if (((lle->la_flags & LLE_DELETED) + || (time_second >= lle->la_expire)) + && (!callout_pending(&lle->la_timer) && + callout_active(&lle->la_timer))) + (void) llentry_free(lle); + else { /* * Still valid, just drop our reference */ |