From 6c56a1874787465138316f6f0f7fb3468e5dedf3 Mon Sep 17 00:00:00 2001 From: Robert Watson Date: Sun, 2 Jan 2005 01:47:56 +0000 Subject: [PATCH] Use RTFREE() to free route references rather than rtfree(), as rtfree() expects a locked route reference. This removes a panic that occurs when connected ipxpcb is closed and its route free'd, and may have been present since the route locking took place. MFC after: 2 weeks --- sys/netipx/ipx_outputfl.c | 2 +- sys/netipx/ipx_pcb.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/netipx/ipx_outputfl.c b/sys/netipx/ipx_outputfl.c index c2585dca38ac..630f792a4107 100644 --- a/sys/netipx/ipx_outputfl.c +++ b/sys/netipx/ipx_outputfl.c @@ -96,7 +96,7 @@ ipx_outputfl(m0, ro, flags) /* * The old route has gone away; try for a new one. */ - rtfree(ro->ro_rt); + RTFREE(ro->ro_rt); ro->ro_rt = NULL; rtalloc_ign(ro, 0); } diff --git a/sys/netipx/ipx_pcb.c b/sys/netipx/ipx_pcb.c index 663cfebd69f5..dbbfa21eb753 100644 --- a/sys/netipx/ipx_pcb.c +++ b/sys/netipx/ipx_pcb.c @@ -275,7 +275,7 @@ ipx_pcbdetach(ipxp) so->so_pcb = 0; sotryfree(so); if (ipxp->ipxp_route.ro_rt != NULL) - rtfree(ipxp->ipxp_route.ro_rt); + RTFREE(ipxp->ipxp_route.ro_rt); LIST_REMOVE(ipxp, ipxp_list); FREE(ipxp, M_PCB); }