projects
/
collectd.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e1eff69
)
openldap: properly free allocated resources on transient errors
author
Marc Fournier
<marc.fournier@camptocamp.com>
Mon, 1 Sep 2014 11:26:38 +0000
(13:26 +0200)
committer
Marc Fournier
<marc.fournier@camptocamp.com>
Mon, 1 Sep 2014 11:26:38 +0000
(13:26 +0200)
src/openldap.c
patch
|
blob
|
history
diff --git
a/src/openldap.c
b/src/openldap.c
index
4d8fa68
..
5b9f8b1
100644
(file)
--- a/
src/openldap.c
+++ b/
src/openldap.c
@@
-69,6
+69,7
@@
static int ldap_init_host (ldap_t *st) /* {{{ */
ERROR ("openldap plugin: ldap_initialize failed: %s",
ldap_err2string (rc));
st->state = 0;
+ ldap_unbind_ext_s (ld, NULL, NULL);
return (-1);
}
@@
-210,6
+211,7
@@
static int ldap_read_host (user_data_t *ud) /* {{{ */
ERROR ("openldap plugin: Failed to execute search: %s",
ldap_err2string (rc));
ldap_msgfree (result);
+ ldap_unbind_ext_s (st->ld, NULL, NULL);
return (-1);
}