svn commit: r202590 - user/luigi/ipfw3-head/sys/netinet/ipfw

Luigi Rizzo luigi at FreeBSD.org
Mon Jan 18 21:00:29 UTC 2010


Author: luigi
Date: Mon Jan 18 21:00:29 2010
New Revision: 202590
URL: http://svn.freebsd.org/changeset/base/202590

Log:
  it is correct to call dn_dequeue on an empty queue

Modified:
  user/luigi/ipfw3-head/sys/netinet/ipfw/dn_sched.h

Modified: user/luigi/ipfw3-head/sys/netinet/ipfw/dn_sched.h
==============================================================================
--- user/luigi/ipfw3-head/sys/netinet/ipfw/dn_sched.h	Mon Jan 18 20:57:50 2010	(r202589)
+++ user/luigi/ipfw3-head/sys/netinet/ipfw/dn_sched.h	Mon Jan 18 21:00:29 2010	(r202590)
@@ -131,7 +131,8 @@ static __inline struct mbuf*
 dn_dequeue(struct new_queue *q)
 {
 	struct mbuf *m = q->mq.head;
-	KASSERT(m != NULL, ("empty queue to dn_return_packet"));
+	if (m == NULL)
+		return NULL;
 	q->mq.head = m->m_nextpkt;
 	q->ni.length--;
 	q->ni.len_bytes -= m->m_pkthdr.len;


More information about the svn-src-user mailing list