fix memory leak when resetting the source address and destination address.
This commit is contained in:
parent
1a6a87b59b
commit
1e5874b3c2
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: if_gif.c,v 1.57 2005/12/28 09:08:20 christos Exp $ */
|
||||
/* $NetBSD: if_gif.c,v 1.58 2006/03/08 03:09:33 msaitoh Exp $ */
|
||||
/* $KAME: if_gif.c,v 1.76 2001/08/20 02:01:02 kjc Exp $ */
|
||||
|
||||
/*
|
||||
|
@ -31,7 +31,7 @@
|
|||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: if_gif.c,v 1.57 2005/12/28 09:08:20 christos Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: if_gif.c,v 1.58 2006/03/08 03:09:33 msaitoh Exp $");
|
||||
|
||||
#include "opt_inet.h"
|
||||
#include "opt_iso.h"
|
||||
|
@ -845,6 +845,13 @@ gif_set_tunnel(struct ifnet *ifp, struct sockaddr *src, struct sockaddr *dst)
|
|||
/* XXX both end must be valid? (I mean, not 0.0.0.0) */
|
||||
}
|
||||
|
||||
#ifdef __HAVE_GENERIC_SOFT_INTERRUPTS
|
||||
if (sc->gif_si) {
|
||||
softintr_disestablish(sc->gif_si);
|
||||
sc->gif_si = NULL;
|
||||
}
|
||||
#endif
|
||||
|
||||
/* XXX we can detach from both, but be polite just in case */
|
||||
if (sc->gif_psrc)
|
||||
switch (sc->gif_psrc->sa_family) {
|
||||
|
|
Loading…
Reference in New Issue