From owner-freebsd-bugs Wed Feb 21 3: 0: 9 2001 Delivered-To: freebsd-bugs@hub.freebsd.org Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by hub.freebsd.org (Postfix) with ESMTP id 77E3337B4EC for ; Wed, 21 Feb 2001 03:00:05 -0800 (PST) (envelope-from gnats@FreeBSD.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.11.1/8.11.1) id f1LB05f25858; Wed, 21 Feb 2001 03:00:05 -0800 (PST) (envelope-from gnats) Date: Wed, 21 Feb 2001 03:00:05 -0800 (PST) Message-Id: <200102211100.f1LB05f25858@freefall.freebsd.org> To: freebsd-bugs@FreeBSD.org Cc: From: "Nick Hilliard" Subject: Re: bin/24798: pac dumps core if "af" is not specified in /etc/printcap Reply-To: "Nick Hilliard" Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org The following reply was made to PR bin/24798; it has been noted by GNATS. From: "Nick Hilliard" To: Peter Pentchev Cc: nick@netability.ie, FreeBSD-gnats-submit@freebsd.org Subject: Re: bin/24798: pac dumps core if "af" is not specified in /etc/printcap Date: Wed, 21 Feb 2001 10:57:37 +0000 > This printf + exit could be rewritten in a more BSD-ish style as: > > err(3, "accounting not enabled for %s", s); yeah, probably. Actually, I was just imitating the printf() & exit() a few lines before for consistency's sake. For convenience, here's the same thing using err: --- pac.c.orig Wed Feb 21 10:53:33 2001 +++ pac.c Wed Feb 21 10:55:50 2001 @@ -450,7 +450,8 @@ case PCAPERR_TCLOOP: fatal(pp, "%s", pcaperr(stat)); } - acctfile = pp->acct_file; + if ((acctfile = pp->acct_file) == NULL) + err(3, "accounting not enabled for %s", s); if (!pflag && pp->price100) price = pp->price100/10000.0; sumfile = (char *) calloc(sizeof(char), strlen(acctfile)+5); Anyway, now that there's a definite schedule for 4.3-release, can someone organise to get one or other of these patchlets committed before the code freeze? Nick To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message