diff options
Diffstat (limited to 'usr.sbin/ypldap')
-rw-r--r-- | usr.sbin/ypldap/aldap.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/usr.sbin/ypldap/aldap.c b/usr.sbin/ypldap/aldap.c index 816b2d5bc36..84bf03af9f1 100644 --- a/usr.sbin/ypldap/aldap.c +++ b/usr.sbin/ypldap/aldap.c @@ -1,5 +1,5 @@ -/* $Id: aldap.c,v 1.7 2008/11/28 10:07:56 aschrijver Exp $ */ -/* $OpenBSD: aldap.c,v 1.7 2008/11/28 10:07:56 aschrijver Exp $ */ +/* $Id: aldap.c,v 1.8 2008/12/27 19:46:12 aschrijver Exp $ */ +/* $OpenBSD: aldap.c,v 1.8 2008/12/27 19:46:12 aschrijver Exp $ */ /* * Copyright (c) 2008 Alexander Schrijver <aschrijver@openbsd.org> @@ -75,6 +75,8 @@ aldap_bind(struct aldap *ldap, char *binddn, char *bindcred) if(ber_write_elements(&ldap->ber, root) == -1) return (-1); + ber_free_elements(root); + return (ldap->msgid); } @@ -92,6 +94,8 @@ aldap_unbind(struct aldap *ldap) if(ber_write_elements(&ldap->ber, root) == -1) return (-1); + ber_free_elements(root); + return (ldap->msgid); } @@ -119,6 +123,8 @@ aldap_search(struct aldap *ldap, char *basedn, enum scope scope, char *filter, if(ber_write_elements(&ldap->ber, root) == -1) return (-1); + ber_free_elements(root); + return (ldap->msgid); } |