summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArthur de Jong <arthur@arthurdejong.org>2008-06-12 21:29:50 +0000
committerArthur de Jong <arthur@arthurdejong.org>2008-06-12 21:29:50 +0000
commit335553af0d1208bf66173608ad55ebe799474fcf (patch)
tree893e9c2b42360c22ac24a6aa24365d6a4abab2eb
parenteaea40927a509553e5b868bca293352301c09995 (diff)
don't perform SSL/TLS sanity checks if it isn't available on the platform
git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-ldapd@757 ef36b2f9-881f-0410-afb5-c4e39611909c
-rw-r--r--nslcd/cfg.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/nslcd/cfg.c b/nslcd/cfg.c
index bab6895..920b5b8 100644
--- a/nslcd/cfg.c
+++ b/nslcd/cfg.c
@@ -877,7 +877,9 @@ static void cfg_read(const char *filename,struct ldap_config *cfg)
void cfg_init(const char *fname)
{
+#ifdef LDAP_OPT_X_TLS
int i;
+#endif /* LDAP_OPT_X_TLS */
/* check if we were called before */
if (nslcd_cfg!=NULL)
{
@@ -902,6 +904,7 @@ void cfg_init(const char *fname)
exit(EXIT_FAILURE);
}
/* if ssl is on each URI should start with https */
+#ifdef LDAP_OPT_X_TLS
if (nslcd_cfg->ldc_ssl_on==SSL_LDAPS)
{
for (i=0;nslcd_cfg->ldc_uris[i].uri!=NULL;i++)
@@ -912,4 +915,5 @@ void cfg_init(const char *fname)
}
}
/* TODO: check that if some tls options are set the ssl option should be set to on (just warn) */
+#endif /* LDAP_OPT_X_TLS */
}