diff options
author | Bob Beck <beck@cvs.openbsd.org> | 2004-03-11 18:14:22 +0000 |
---|---|---|
committer | Bob Beck <beck@cvs.openbsd.org> | 2004-03-11 18:14:22 +0000 |
commit | 953b473214f2286c7565f2db3d64bf3aab81c8ab (patch) | |
tree | 1b236b43006e5a50b6f39c3f80c984110ca5e480 /usr.sbin | |
parent | 1a95f1cc5ba35d059e81222a6dc9a1ce3bd73159 (diff) |
fix leak, found by Patrick Latifi <pat@eyeo.org>
ok millert@, dhartmei@
Diffstat (limited to 'usr.sbin')
-rw-r--r-- | usr.sbin/spamdb/spamdb.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/usr.sbin/spamdb/spamdb.c b/usr.sbin/spamdb/spamdb.c index 96be5dca301..74cdcad2bdb 100644 --- a/usr.sbin/spamdb/spamdb.c +++ b/usr.sbin/spamdb/spamdb.c @@ -1,4 +1,4 @@ -/* $OpenBSD: spamdb.c,v 1.6 2004/03/11 18:09:43 beck Exp $ */ +/* $OpenBSD: spamdb.c,v 1.7 2004/03/11 18:14:21 beck Exp $ */ /* * Copyright (c) 2004 Bob Beck. All rights reserved. @@ -197,6 +197,7 @@ dblist(char *dbname) to = strchr(from, '\n'); if (to == NULL) { warnx("No from part in grey key %s", a); + free(a); goto bad; } *to = '\0'; @@ -205,6 +206,7 @@ dblist(char *dbname) a, from, to, gd.first, gd.pass, gd.expire, gd.bcount, gd.pcount); } + free(a); } db->close(db); db = NULL; |