From owner-cvs-all@FreeBSD.ORG Thu Jun 7 21:41:52 2007 Return-Path: X-Original-To: cvs-all@FreeBSD.org Delivered-To: cvs-all@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 0ED6D16A41F; Thu, 7 Jun 2007 21:41:52 +0000 (UTC) (envelope-from andre@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [69.147.83.41]) by mx1.freebsd.org (Postfix) with ESMTP id DCFC213C45D; Thu, 7 Jun 2007 21:41:51 +0000 (UTC) (envelope-from andre@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.8/8.13.8) with ESMTP id l57Lfpwr044837; Thu, 7 Jun 2007 21:41:51 GMT (envelope-from andre@repoman.freebsd.org) Received: (from andre@localhost) by repoman.freebsd.org (8.13.8/8.13.8/Submit) id l57Lfpup044829; Thu, 7 Jun 2007 21:41:51 GMT (envelope-from andre) Message-Id: <200706072141.l57Lfpup044829@repoman.freebsd.org> From: Andre Oppermann Date: Thu, 7 Jun 2007 21:41:51 +0000 (UTC) To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org X-FreeBSD-CVS-Branch: HEAD Cc: Subject: cvs commit: src/sys/netinet tcp_hostcache.c X-BeenThere: cvs-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: CVS commit messages for the entire tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 07 Jun 2007 21:41:52 -0000 andre 2007-06-07 21:41:51 UTC FreeBSD src repository Modified files: sys/netinet tcp_hostcache.c Log: In tcp_hc_insert() we may have the case where we have hit the global cache size limit but this bucket row is empty. Normally we want to recycle the oldest entry in the bucket row. If there isn't any the TAILQ_REMOVE leads to a panic by trying to remove a non-existing element. Fix this by just returning NULL and failing the insert. This is not a problem as the TCP hostache is only advisory. Submitted by: jhb Revision Changes Path 1.14 +6 -0 src/sys/netinet/tcp_hostcache.c