dirmngr: Fix resource leaks and check rare errors.
authorWerner Koch <wk@gnupg.org>
Wed, 25 Mar 2015 18:39:27 +0000 (19:39 +0100)
committerWerner Koch <wk@gnupg.org>
Wed, 25 Mar 2015 18:39:27 +0000 (19:39 +0100)
commitbec10ae4b5a870303c800cdf3cd906044613fc2d
tree0d10423429f33a09b7a1793858c52b942aa10a88
parent6c701af121782c2feb4ee51e559a7420df00471f
dirmngr: Fix resource leaks and check rare errors.

* dirmngr/ks-engine-ldap.c (keyspec_to_ldap_filter): Fix resource
leak.
(ks_ldap_search): Check error from es_fopenmem.  Use LDAP_ERR where
required.
(modlist_dump): Check error from es_fopenmem.
(uncescape): s/int/size_t/.  Use existing macros.
(extract_attributes): Use existing trim function.
(ks_ldap_put): Do not segv on error from modlist_dump.

Signed-off-by: Werner Koch <wk@gnupg.org>
dirmngr/ks-engine-ldap.c