summaryrefslogtreecommitdiff
path: root/modules/ldap
diff options
context:
space:
mode:
authorStefan Fritsch <sf@sfritsch.de>2015-04-28 22:06:31 +0200
committerStefan Fritsch <sf@sfritsch.de>2015-04-28 22:06:31 +0200
commit080d5e16db802902200a9ce5b6c40f8f1fdc1f73 (patch)
tree69845ca856fe6817f103544e88541d80411fe9a8 /modules/ldap
parentcb35beef2a938b80c9e4b5d6a408eca437aa74db (diff)
downloadapache2-080d5e16db802902200a9ce5b6c40f8f1fdc1f73.tar.gz
Imported Upstream version 2.4.12
Diffstat (limited to 'modules/ldap')
-rw-r--r--modules/ldap/util_ldap.c2
-rw-r--r--modules/ldap/util_ldap_cache_mgr.c8
2 files changed, 6 insertions, 4 deletions
diff --git a/modules/ldap/util_ldap.c b/modules/ldap/util_ldap.c
index 0cc51c40..7440d9eb 100644
--- a/modules/ldap/util_ldap.c
+++ b/modules/ldap/util_ldap.c
@@ -1824,7 +1824,7 @@ start_over:
* combination, which might be reused unintentionally next time this
* connection is used from the connection pool.
*/
- ldc->must_rebind = 0;
+ ldc->must_rebind = 1;
ap_log_rerror(APLOG_MARK, APLOG_TRACE5, 0, r, "LDC %pp used for authn, must be rebound", ldc);
}
diff --git a/modules/ldap/util_ldap_cache_mgr.c b/modules/ldap/util_ldap_cache_mgr.c
index ae7e652a..2389b5d0 100644
--- a/modules/ldap/util_ldap_cache_mgr.c
+++ b/modules/ldap/util_ldap_cache_mgr.c
@@ -359,9 +359,11 @@ util_ald_cache_t *util_ald_create_cache(util_ldap_state_t *st,
cache->maxentries = cache_size;
cache->numentries = 0;
cache->size = cache_size / 3;
- if (cache->size < 64) cache->size = 64;
- for (i = 0; primes[i] && primes[i] < cache->size; ++i) ;
- cache->size = primes[i]? primes[i] : primes[i-1];
+ if (cache->size < 64)
+ cache->size = 64;
+ for (i = 0; primes[i] && primes[i] < cache->size; ++i)
+ ;
+ cache->size = primes[i] ? primes[i] : primes[i-1];
cache->nodes = (util_cache_node_t **)util_ald_alloc(cache, cache->size * sizeof(util_cache_node_t *));
if (!cache->nodes) {