From 0597c8cf73fc5889ce4e2cf4c98e7900573f3d65 Mon Sep 17 00:00:00 2001 From: Robert Watson Date: Sun, 26 Mar 2006 02:33:44 +0000 Subject: [PATCH] Restore original formulation of SPX segment queue draining during SPX PCB detach. MFC after: 1 month --- sys/netipx/spx_usrreq.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/sys/netipx/spx_usrreq.c b/sys/netipx/spx_usrreq.c index 8054c27e510..dad3cd934a8 100644 --- a/sys/netipx/spx_usrreq.c +++ b/sys/netipx/spx_usrreq.c @@ -1427,7 +1427,9 @@ spx_pcbdetach(struct ipxpcb *ipxp) cb = ipxtospxpcb(ipxp); KASSERT(cb != NULL, ("spx_pcbdetach: cb == NULL")); - for (s = cb->s_q.si_next; s != NULL; s = cb->s_q.si_next) { + s = cb->s_q.si_next; + while (s != &(cb->s_q)) { + s = s->si_next; remque(s); m = dtom(s); m_freem(m);