PR/50666: David Binderman:
He's out of jail and out of bail and that's the way it goes: free(base);
This commit is contained in:
parent
8d60259f07
commit
bf07f60056
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: pac.c,v 1.23 2011/08/30 19:27:37 joerg Exp $ */
|
||||
/* $NetBSD: pac.c,v 1.24 2016/01/17 14:50:31 christos Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1983, 1993
|
||||
@ -37,7 +37,7 @@ __COPYRIGHT("@(#) Copyright (c) 1983, 1993\
|
||||
#if 0
|
||||
static char sccsid[] = "@(#)pac.c 8.1 (Berkeley) 6/6/93";
|
||||
#else
|
||||
__RCSID("$NetBSD: pac.c,v 1.23 2011/08/30 19:27:37 joerg Exp $");
|
||||
__RCSID("$NetBSD: pac.c,v 1.24 2016/01/17 14:50:31 christos Exp $");
|
||||
#endif
|
||||
#endif /* not lint */
|
||||
|
||||
@ -255,7 +255,7 @@ dumpit(void)
|
||||
|
||||
hp = hashtab[0];
|
||||
hno = 1;
|
||||
base = (struct hent **) calloc(sizeof hp, hcount);
|
||||
base = calloc(sizeof hp, hcount);
|
||||
if (base == NULL)
|
||||
err(1, "calloc");
|
||||
for (ap = base, c = hcount; c--; ap++) {
|
||||
@ -284,6 +284,7 @@ dumpit(void)
|
||||
printf("Sum:%7.2f %4d $%7.2f\n", feet, runs,
|
||||
feet * price * runs);
|
||||
}
|
||||
free(base);
|
||||
}
|
||||
|
||||
/*
|
||||
|
Loading…
Reference in New Issue
Block a user