diff options
author | Sergey Poznyakoff <gray@gnu.org.ua> | 2011-03-19 10:25:10 +0200 |
---|---|---|
committer | Sergey Poznyakoff <gray@gnu.org.ua> | 2011-03-19 11:23:28 +0200 |
commit | 39eab1b4b01d790bde3a1e5119ae00b219681520 (patch) | |
tree | 9291505a48a63d6a725e6cac1eeb89e18cc1d541 /src/main.c | |
parent | 6e030ce89c5bb3f8691108275c023abe7c697391 (diff) | |
download | mailfromd-39eab1b4b01d790bde3a1e5119ae00b219681520.tar.gz mailfromd-39eab1b4b01d790bde3a1e5119ae00b219681520.tar.bz2 |
Restore lock-retry-count and lock-retry-timeout configuration statements
* lib/mf-dbm.h (lock_retry_timeout_option): New extern.
* lib/libmf.h (mf_option_time_t, config_cb_time_t): New protos.
* lib/optcache.c (mf_option_time_t): New function.
* lib/utils.c (config_cb_time_t): New function.
* src/main.c (mf_cfg_param): Restore lock-retry-count
and lock-retry-timeout statements.
(cb_timeout): Remove. Use config_cb_timeout instead
* mfdbtool.c (options, parse_opt): Enable --lock-retry-count
and --lock-retry-timeout options,
(option_cache): Define lock-retry-count and lock-retry-timeout
caches.
* TODO: Update
Diffstat (limited to 'src/main.c')
-rw-r--r-- | src/main.c | 17 |
1 files changed, 7 insertions, 10 deletions
@@ -708,16 +708,6 @@ cb_milter_timeout(void *data, mu_config_value_t *arg) } static int -cb_timeout(void *data, mu_config_value_t *arg) -{ - struct timeval tv; - int rc = config_cb_timeout (&tv, arg); - if (rc == 0) - *(time_t*) data = tv.tv_sec; - return rc; -} - -static int cb_set_variable(void *data, mu_config_value_t *arg) { const char *value; @@ -907,6 +897,13 @@ struct mu_cfg_param mf_cfg_param[] = { { "database", mu_cfg_section, NULL }, + { "lock-retry-count", mu_cfg_size, &lock_retry_count_option, 0, NULL, + N_("Retry acquiring DBM file lock this number of times.") }, + { "lock-retry-timeout", mu_cfg_callback, &lock_retry_timeout_option, 0, + config_cb_time_t, + N_("Set the time span between the two DBM locking attempts."), + N_("time") }, + { "max-match-mx", mu_cfg_size, &max_match_mx, 0, NULL, N_("Maximum number of MXs used by MFL \"mx match\" operation.") }, |