Do not call nd6_purge() before purging the IPv6 addresses of a detached
authormpi <mpi@openbsd.org>
Mon, 27 Apr 2015 14:51:44 +0000 (14:51 +0000)
committermpi <mpi@openbsd.org>
Mon, 27 Apr 2015 14:51:44 +0000 (14:51 +0000)
commite520a0ec7a758fda4db3d6ff0e78ab2c0013225e
treec90c91220d9e13697709f82640ba1052a846bced
parent03ed85e124d59134107086d60805466cbd0321f3
Do not call nd6_purge() before purging the IPv6 addresses of a detached
interface.

Fix a use after free introduced in r1.98 of netinet6/in6.c and recently
exposed by a crazy pool/malloc damage finder being currently refined by
dlg@ and deraadt@.

ok mikeb@, henning@
sys/netinet6/in6_ifattach.c
sys/netinet6/nd6.c
sys/netinet6/nd6_rtr.c