From c97198371b7307e64afdd323231977b2247f64ec Mon Sep 17 00:00:00 2001 From: Werner Koch Date: Thu, 18 Jun 2015 13:34:48 +0200 Subject: dirmngr: Fix the cleanup zombies fix (685b782). * dirmngr/ldap-wrapper.c (ldap_wrapper_thread): Do not close the stdout reader after EOF from read_log_data. * dirmngr/crlcache.c (crl_cache_reload_crl): Close the reader before the next iteration. -- I assumed that the log_fd also has a reader object but that reader object is used for stdout and needs to be closed by the consumer. The real bug with the non-released ldap_wrapper control objects was that when looping over distribution points we did not closed the used reader object before the next iteration. Now, the test case had more than one DP and thus we lost one reader object. Signed-off-by: Werner Koch --- dirmngr/ldap-wrapper.c | 2 -- 1 file changed, 2 deletions(-) (limited to 'dirmngr/ldap-wrapper.c') diff --git a/dirmngr/ldap-wrapper.c b/dirmngr/ldap-wrapper.c index 0dcc7baf5..a54e40523 100644 --- a/dirmngr/ldap-wrapper.c +++ b/dirmngr/ldap-wrapper.c @@ -325,8 +325,6 @@ ldap_wrapper_thread (void *dummy) { if (read_log_data (ctx)) { - ksba_reader_release (ctx->reader); - ctx->reader = NULL; SAFE_CLOSE (ctx->log_fd); any_action = 1; } -- cgit v1.2.3