From owner-freebsd-bugs Sun Sep 8 5: 0:25 2002 Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id C4B5E37B400 for ; Sun, 8 Sep 2002 05:00:16 -0700 (PDT) Received: from freefall.freebsd.org (freefall.FreeBSD.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8135443E42 for ; Sun, 8 Sep 2002 05:00:16 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.12.4/8.12.4) with ESMTP id g88C0GJU012981 for ; Sun, 8 Sep 2002 05:00:16 -0700 (PDT) (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.12.4/8.12.4/Submit) id g88C0GeQ012979; Sun, 8 Sep 2002 05:00:16 -0700 (PDT) Date: Sun, 8 Sep 2002 05:00:16 -0700 (PDT) Message-Id: <200209081200.g88C0GeQ012979@freefall.freebsd.org> To: freebsd-bugs@FreeBSD.org Cc: From: Mike Makonnen Subject: Re: bin/42544: ifconfig.core, nonsense syntax causes "Segmentation fault" in ifconfig Reply-To: Mike Makonnen Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org The following reply was made to PR bin/42544; it has been noted by GNATS. From: Mike Makonnen To: vd@etrade.bg Cc: FreeBSD-gnats-submit@FreeBSD.ORG Subject: Re: bin/42544: ifconfig.core, nonsense syntax causes "Segmentation fault" in ifconfig Date: Sun, 08 Sep 2002 05:11:44 -0700 Hello Vasil, Please apply the following patch. It should fix your problem. Cheers, Mike Makonnen. Index: sbin/ifconfig/ifconfig.c =================================================================== RCS file: /home/ncvs/src/sbin/ifconfig/ifconfig.c,v retrieving revision 1.79 diff -u -r1.79 ifconfig.c --- sbin/ifconfig/ifconfig.c 19 Aug 2002 15:18:24 -0000 1.79 +++ sbin/ifconfig/ifconfig.c 8 Sep 2002 12:05:12 -0000 @@ -963,9 +963,10 @@ notealias(const char *addr, int param, int s, const struct afswtch *afp) { if (setaddr && doalias == 0 && param < 0) - bcopy((caddr_t)rqtosa(af_addreq), - (caddr_t)rqtosa(af_ridreq), - rqtosa(af_addreq)->sa_len); + if (afp->af_addreq != NULL && afp->af_ridreq != NULL) + bcopy((caddr_t)rqtosa(af_addreq), + (caddr_t)rqtosa(af_ridreq), + rqtosa(af_addreq)->sa_len); doalias = param; if (param < 0) { clearaddr = 1; To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message