diff options
author | Peter Valchev <pvalchev@cvs.openbsd.org> | 2003-06-19 07:21:21 +0000 |
---|---|---|
committer | Peter Valchev <pvalchev@cvs.openbsd.org> | 2003-06-19 07:21:21 +0000 |
commit | 8820cccc99f9e64a1764fc8b097ee4a321e18d36 (patch) | |
tree | 401e3257489656e7a89eeb4c245453f645188eed /usr.sbin | |
parent | f54e7db8dd3f8b752ad9a007594e9e2cdf778820 (diff) |
plug memory leak; ok solar, camield
Diffstat (limited to 'usr.sbin')
-rw-r--r-- | usr.sbin/popa3d/virtual.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/usr.sbin/popa3d/virtual.c b/usr.sbin/popa3d/virtual.c index 0d4da4f43aa..3ec70d7d535 100644 --- a/usr.sbin/popa3d/virtual.c +++ b/usr.sbin/popa3d/virtual.c @@ -1,4 +1,4 @@ -/* $OpenBSD: virtual.c,v 1.4 2003/04/02 00:07:53 deraadt Exp $ */ +/* $OpenBSD: virtual.c,v 1.5 2003/06/19 07:21:20 pvalchev Exp $ */ /* * Virtual domain support. @@ -117,7 +117,10 @@ struct passwd *virtual_userpass(char *user, char *pass, int *known) return NULL; } - if (!(address = strdup(address))) return NULL; + if (!(address = strdup(address))) { + free(pathname); + return NULL; + } virtual_domain = address; free(pathname); |