From owner-cvs-all@FreeBSD.ORG Tue Apr 5 13:04:35 2005 Return-Path: Delivered-To: cvs-all@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B2CFA16A4CE; Tue, 5 Apr 2005 13:04:35 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9AB9343D48; Tue, 5 Apr 2005 13:04:35 +0000 (GMT) (envelope-from phk@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j35D4ZF0042503; Tue, 5 Apr 2005 13:04:35 GMT (envelope-from phk@repoman.freebsd.org) Received: (from phk@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j35D4ZiX042502; Tue, 5 Apr 2005 13:04:35 GMT (envelope-from phk) Message-Id: <200504051304.j35D4ZiX042502@repoman.freebsd.org> From: Poul-Henning Kamp Date: Tue, 5 Apr 2005 13:04:35 +0000 (UTC) To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org X-FreeBSD-CVS-Branch: HEAD Subject: cvs commit: src/lib/libalias alias.c X-BeenThere: cvs-all@freebsd.org X-Mailman-Version: 2.1.1 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: Tue, 05 Apr 2005 13:04:35 -0000 phk 2005-04-05 13:04:35 UTC FreeBSD src repository Modified files: lib/libalias alias.c Log: natd core dumps when -reverse switch is used because of a bug in libalias. In /usr/src/lib/libalias/alias.c, the functions LibAliasIn and LibAliasOutTry call the legacy PacketAliasIn/PacketAliasOut instead of LibAliasIn/LibAliasOut when the PKT_ALIAS_REVERSE option is set. In this case, the context variable "la" gets lost because the legacy compatibility routines expect "la" to be global. This was obviously an oversight when rewriting the PacketAlias* functions to the LibAlias* functions. The fix (as shown in the patch below) is to remove the legacy subroutine calls and replace with the new ones using the "la" struct as the first arg. Submitted by: Gil Kloepfer Confirmed by: PR: 76839 MFC after: 3 days Revision Changes Path 1.50 +2 -2 src/lib/libalias/alias.c