From owner-svn-src-user@FreeBSD.ORG Sun Jan 31 12:20:29 2010 Return-Path: Delivered-To: svn-src-user@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 6EEBF1065676; Sun, 31 Jan 2010 12:20:29 +0000 (UTC) (envelope-from luigi@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 5E7858FC14; Sun, 31 Jan 2010 12:20:29 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id o0VCKThQ021695; Sun, 31 Jan 2010 12:20:29 GMT (envelope-from luigi@svn.freebsd.org) Received: (from luigi@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id o0VCKTP3021693; Sun, 31 Jan 2010 12:20:29 GMT (envelope-from luigi@svn.freebsd.org) Message-Id: <201001311220.o0VCKTP3021693@svn.freebsd.org> From: Luigi Rizzo Date: Sun, 31 Jan 2010 12:20:29 +0000 (UTC) To: src-committers@freebsd.org, svn-src-user@freebsd.org X-SVN-Group: user MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r203279 - user/luigi/ipfw3-head/sys/netinet/ipfw X-BeenThere: svn-src-user@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the experimental " user" src tree" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 31 Jan 2010 12:20:29 -0000 Author: luigi Date: Sun Jan 31 12:20:29 2010 New Revision: 203279 URL: http://svn.freebsd.org/changeset/base/203279 Log: don't panic if passed a NULL pointer to dn_ht_entries() Modified: user/luigi/ipfw3-head/sys/netinet/ipfw/dn_heap.c Modified: user/luigi/ipfw3-head/sys/netinet/ipfw/dn_heap.c ============================================================================== --- user/luigi/ipfw3-head/sys/netinet/ipfw/dn_heap.c Sun Jan 31 12:07:13 2010 (r203278) +++ user/luigi/ipfw3-head/sys/netinet/ipfw/dn_heap.c Sun Jan 31 12:20:29 2010 (r203279) @@ -392,7 +392,7 @@ dn_ht_free(struct dn_ht *ht, int flags) int dn_ht_entries(struct dn_ht *ht) { - return ht->entries; + return ht ? ht->entries : 0; } /* lookup and optionally create or delete element */