From 4772d3f1fe5015a25ba1fb4c3779ee3117ec6fcb Mon Sep 17 00:00:00 2001 From: Pavel Reichl Date: Tue, 4 Aug 2015 09:30:06 -0400 Subject: LDAP: minor improvements in ldap id cleanup MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Reviewed-by: Pavel Březina --- src/providers/ldap/ldap_id_cleanup.c | 6 +++--- src/providers/ldap/sdap_async_enum.c | 3 ++- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/src/providers/ldap/ldap_id_cleanup.c b/src/providers/ldap/ldap_id_cleanup.c index e44e48549..0a2b23297 100644 --- a/src/providers/ldap/ldap_id_cleanup.c +++ b/src/providers/ldap/ldap_id_cleanup.c @@ -436,10 +436,10 @@ static int cleanup_groups(TALLOC_CTX *memctx, ret, strerror(ret)); goto done; } - } - if (ret != EOK) { + } else if (ret != EOK) { DEBUG(SSSDBG_CRIT_FAILURE, - "Failed to search sysdb using %s: %d\n", subfilter, ret); + "Failed to search sysdb using %s: [%d] %s\n", + subfilter, ret, sss_strerror(ret)); goto done; } talloc_zfree(u_msgs); diff --git a/src/providers/ldap/sdap_async_enum.c b/src/providers/ldap/sdap_async_enum.c index 2d3821542..a7ad5609d 100644 --- a/src/providers/ldap/sdap_async_enum.c +++ b/src/providers/ldap/sdap_async_enum.c @@ -487,7 +487,8 @@ static void sdap_dom_enum_ex_svcs_done(struct tevent_req *subreq) /* Not fatal, worst case we'll have stale entries that would be * removed on a subsequent online lookup */ - DEBUG(SSSDBG_MINOR_FAILURE, "Cleanup failed: %d\n", ret); + DEBUG(SSSDBG_MINOR_FAILURE, "Cleanup failed: [%d]: %s\n", + ret, sss_strerror(ret)); } } -- cgit