summaryrefslogtreecommitdiff
path: root/nslcd/cfg.c
diff options
context:
space:
mode:
authorArthur de Jong <arthur@arthurdejong.org>2007-09-09 10:30:18 +0000
committerArthur de Jong <arthur@arthurdejong.org>2007-09-09 10:30:18 +0000
commit3c0422d53b51bc72860e82ae55c1e9d708d23ae7 (patch)
treef71ed69c4e977b5807bb8d396e9f2e402e91f4fb /nslcd/cfg.c
parent0e34be5958a08db6dc02c918dce0fa5f25d5fd6b (diff)
some simplifications in the reconnect loging, removing the undocumented nss_reconnect_maxconntries configfile option and some work to split out LDAP compatibility code to a separate file
git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-ldapd@388 ef36b2f9-881f-0410-afb5-c4e39611909c
Diffstat (limited to 'nslcd/cfg.c')
-rw-r--r--nslcd/cfg.c10
1 files changed, 2 insertions, 8 deletions
diff --git a/nslcd/cfg.c b/nslcd/cfg.c
index d9d32f6..5577198 100644
--- a/nslcd/cfg.c
+++ b/nslcd/cfg.c
@@ -49,8 +49,8 @@ struct ldap_config *nslcd_cfg=NULL;
* the constants below.
*/
#define LDAP_NSS_TRIES 5 /* number of sleeping reconnect attempts */
-#define LDAP_NSS_SLEEPTIME 4 /* seconds to sleep; doubled until max */
-#define LDAP_NSS_MAXSLEEPTIME 64 /* maximum seconds to sleep */
+#define LDAP_NSS_SLEEPTIME 1 /* seconds to sleep; doubled until max */
+#define LDAP_NSS_MAXSLEEPTIME 32 /* maximum seconds to sleep */
#define LDAP_NSS_MAXCONNTRIES 2 /* reconnect attempts before sleeping */
/* the maximum line length in the configuration file */
@@ -112,7 +112,6 @@ static void cfg_defaults(struct ldap_config *cfg)
cfg->ldc_reconnect_tries=LDAP_NSS_TRIES;
cfg->ldc_reconnect_sleeptime=LDAP_NSS_SLEEPTIME;
cfg->ldc_reconnect_maxsleeptime=LDAP_NSS_MAXSLEEPTIME;
- cfg->ldc_reconnect_maxconntries=LDAP_NSS_MAXCONNTRIES;
cfg->ldc_debug=0;
cfg->ldc_password_type=LU_RFC2307_USERPASSWORD;
cfg->ldc_shadow_type=LS_RFC2307_SHADOW;
@@ -668,11 +667,6 @@ static void cfg_read(const char *filename,struct ldap_config *cfg)
check_argumentcount(filename,lnr,opts[0],nopts==2);
cfg->ldc_reconnect_maxsleeptime=atoi(opts[1]);
}
- else if (strcasecmp(opts[0],"nss_reconnect_maxconntries")==0)
- {
- check_argumentcount(filename,lnr,opts[0],nopts==2);
- cfg->ldc_reconnect_maxconntries=atoi(opts[1]);
- }
else
{
log_log(LOG_ERR,"%s:%d: unknown keyword: '%s'",filename,lnr,opts[0]);