fix sall memory leak. from Christopher Jon Kane <kane@kidd.vet.purdue.edu>
This commit is contained in:
parent
8cdd7bfe4f
commit
98a60eb83a
|
@ -36,7 +36,7 @@
|
|||
|
||||
#if defined(LIBC_SCCS) && !defined(lint)
|
||||
/* from: static char sccsid[] = "@(#)hash.c 8.4 (Berkeley) 10/12/93"; */
|
||||
static char *rcsid = "$Id: hash.c,v 1.5 1993/10/20 07:26:09 cgd Exp $";
|
||||
static char *rcsid = "$Id: hash.c,v 1.6 1994/01/13 22:55:55 cgd Exp $";
|
||||
#endif /* LIBC_SCCS and not lint */
|
||||
|
||||
#include <sys/param.h>
|
||||
|
@ -434,6 +434,8 @@ hdestroy(hashp)
|
|||
if (hashp->fp != -1)
|
||||
(void)close(hashp->fp);
|
||||
|
||||
free(hashp);
|
||||
|
||||
if (save_errno) {
|
||||
errno = save_errno;
|
||||
return (ERROR);
|
||||
|
|
Loading…
Reference in New Issue