From b6ed1d6569fea94cb58d91877c1873ec28328fd7 Mon Sep 17 00:00:00 2001 From: Jakub Hrozek Date: Fri, 4 Mar 2011 22:17:55 +0100 Subject: Don't pass NULL to printf for TLS errors https://fedorahosted.org/sssd/ticket/643 Conflicts: src/util/sss_ldap.h --- src/util/sss_ldap.h | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'src/util/sss_ldap.h') diff --git a/src/util/sss_ldap.h b/src/util/sss_ldap.h index 2643e82f..df96b9dc 100644 --- a/src/util/sss_ldap.h +++ b/src/util/sss_ldap.h @@ -27,6 +27,20 @@ #include #include +#ifdef LDAP_OPT_DIAGNOSTIC_MESSAGE +#define SDAP_DIAGNOSTIC_MESSAGE LDAP_OPT_DIAGNOSTIC_MESSAGE +#else +#ifdef LDAP_OPT_ERROR_STRING +#define SDAP_DIAGNOSTIC_MESSAGE LDAP_OPT_ERROR_STRING +#else +#error No extended diagnostic message available +#endif +#endif + +int sss_ldap_get_diagnostic_msg(TALLOC_CTX *mem_ctx, + LDAP *ld, + char **_errmsg); + int sss_ldap_control_create(const char *oid, int iscritical, struct berval *value, int dupval, LDAPControl **ctrlp); -- cgit