summaryrefslogtreecommitdiffstats
path: root/src/plugins
diff options
context:
space:
mode:
Diffstat (limited to 'src/plugins')
-rw-r--r--src/plugins/kdb/ldap/libkdb_ldap/ldap_service_stash.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/plugins/kdb/ldap/libkdb_ldap/ldap_service_stash.c b/src/plugins/kdb/ldap/libkdb_ldap/ldap_service_stash.c
index 99e7821ce..865fe21a1 100644
--- a/src/plugins/kdb/ldap/libkdb_ldap/ldap_service_stash.c
+++ b/src/plugins/kdb/ldap/libkdb_ldap/ldap_service_stash.c
@@ -50,6 +50,11 @@ krb5_ldap_readpassword(context, ldap_context, password)
if (ldap_context->service_password_file)
file = ldap_context->service_password_file;
+#ifndef HAVE_STRERROR_R
+# undef strerror_r
+# define strerror_r(ERRNUM, BUF, SIZE) (strncpy(BUF, strerror(ERRNUM), SIZE), BUF[(SIZE)-1] = 0)
+#endif
+
/* check whether file exists */
if (access(file, F_OK) < 0) {
st = errno;