diff options
| author | 2010-07-06 20:02:33 +0000 | |
|---|---|---|
| committer | 2010-07-06 20:02:33 +0000 | |
| commit | 6a906d3323bd8c5797debb3cca3da26f861bb865 (patch) | |
| tree | 07531a32b8c19941c5a5aa0af9e99e244859d9d6 /usr.sbin/ldapd/modify.c | |
| parent | one wire counter driver 2nd rev, from John L. Scarfone" <j0@cox.net> PR 6422 (diff) | |
| download | wireguard-openbsd-6a906d3323bd8c5797debb3cca3da26f861bb865.tar.xz wireguard-openbsd-6a906d3323bd8c5797debb3cca3da26f861bb865.zip | |
Plug another memory leak. Forgot to reset key returned from cursor, having
a reference to a cached page.
Diffstat (limited to 'usr.sbin/ldapd/modify.c')
| -rw-r--r-- | usr.sbin/ldapd/modify.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/usr.sbin/ldapd/modify.c b/usr.sbin/ldapd/modify.c index fd442c494a8..5487ae78480 100644 --- a/usr.sbin/ldapd/modify.c +++ b/usr.sbin/ldapd/modify.c @@ -1,4 +1,4 @@ -/* $OpenBSD: modify.c,v 1.11 2010/07/06 09:27:05 martinh Exp $ */ +/* $OpenBSD: modify.c,v 1.12 2010/07/06 20:02:33 martinh Exp $ */ /* * Copyright (c) 2009, 2010 Martin Hedenfalk <martin@bzero.se> @@ -81,6 +81,7 @@ ldap_delete(struct request *req) goto done; } + btval_reset(&key); if (btree_cursor_get(cursor, &key, NULL, BT_NEXT) != 0) { if (errno != ENOENT) goto done; @@ -94,6 +95,7 @@ ldap_delete(struct request *req) done: btree_cursor_close(cursor); + btval_reset(&key); namespace_abort(ns); return ldap_respond(req, rc); } |
