diff options
author | sam <sam@FreeBSD.org> | 2003-11-28 04:19:41 +0000 |
---|---|---|
committer | sam <sam@FreeBSD.org> | 2003-11-28 04:19:41 +0000 |
commit | 9f0b8cac1eb7f7f814567ba61355226394431462 (patch) | |
tree | 3132b7663e3a2b8a57d57452506fc37105c9185a | |
parent | 5868bd1269d8837597b4a4e6d93e58e537c06e6f (diff) | |
download | FreeBSD-src-9f0b8cac1eb7f7f814567ba61355226394431462.zip FreeBSD-src-9f0b8cac1eb7f7f814567ba61355226394431462.tar.gz |
Eliminate a duplicate free when deleting an interface address. This
caused crashes, typically during shutdown, because the second free
referenced a mutex that had been destroyed.
Tested by: several
Approved by: re (scottl)
-rw-r--r-- | sys/netatalk/at_control.c | 12 |
1 files changed, 1 insertions, 11 deletions
diff --git a/sys/netatalk/at_control.c b/sys/netatalk/at_control.c index d7e7586..866df04 100644 --- a/sys/netatalk/at_control.c +++ b/sys/netatalk/at_control.c @@ -273,12 +273,6 @@ at_control(struct socket *so, u_long cmd, caddr_t data, TAILQ_REMOVE(&ifp->if_addrhead, ifa0, ifa_link); /* - * refs goes from 1->0 if no external refs. note.. - * This will not free it ... looks for -1. - */ - IFAFREE(ifa0); - - /* * Now remove the at_ifaddr from the parallel structure * as well, or we'd be in deep trouble */ @@ -301,11 +295,7 @@ at_control(struct socket *so, u_long cmd, caddr_t data, } /* - * Now dump the memory we were using. - * Decrement the reference count. - * This should probably be the last reference - * as the count will go from 0 to -1. - * (unless there is still a route referencing this) + * Now reclaim the reference. */ IFAFREE(ifa0); break; |