diff options
author | Aaron Campbell <aaron@cvs.openbsd.org> | 2001-07-11 16:11:11 +0000 |
---|---|---|
committer | Aaron Campbell <aaron@cvs.openbsd.org> | 2001-07-11 16:11:11 +0000 |
commit | 05a6b837afae35d77308432f0245de60a95f4e65 (patch) | |
tree | 29c861f4a72502b090beb23829865647b02acbe8 /lib/libutil/passwd.c | |
parent | 936a56aaf15825deb21d951563f65d77cfb21c0d (diff) |
Plug memory leak in pw_copy(); millert@ ok
Diffstat (limited to 'lib/libutil/passwd.c')
-rw-r--r-- | lib/libutil/passwd.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/libutil/passwd.c b/lib/libutil/passwd.c index a3a2f534875..ea86b1e1e3d 100644 --- a/lib/libutil/passwd.c +++ b/lib/libutil/passwd.c @@ -1,4 +1,4 @@ -/* $OpenBSD: passwd.c,v 1.25 2001/07/09 07:04:40 deraadt Exp $ */ +/* $OpenBSD: passwd.c,v 1.26 2001/07/11 16:11:10 aaron Exp $ */ /* * Copyright (c) 1987, 1993, 1994, 1995 @@ -34,7 +34,7 @@ */ #if defined(LIBC_SCCS) && !defined(lint) -static char rcsid[] = "$OpenBSD: passwd.c,v 1.25 2001/07/09 07:04:40 deraadt Exp $"; +static char rcsid[] = "$OpenBSD: passwd.c,v 1.26 2001/07/11 16:11:10 aaron Exp $"; #endif /* LIBC_SCCS and not lint */ #include <sys/types.h> @@ -485,6 +485,7 @@ pw_copy(ffd, tfd, pw) if (ferror(to)) err: pw_error(NULL, 0, 1); + free(master); (void)fclose(to); } |