dovecot-1.1: dict: Register dicts only after loading modules. Th...
dovecot at dovecot.org
dovecot at dovecot.org
Sun Oct 5 14:22:32 EEST 2008
details: http://hg.dovecot.org/dovecot-1.1/rev/645ea17b4950
changeset: 7906:645ea17b4950
user: Timo Sirainen <tss at iki.fi>
date: Sun Oct 05 14:22:28 2008 +0300
description:
dict: Register dicts only after loading modules. This allows using SQL drivers from modules.
diffstat:
1 file changed, 4 insertions(+), 2 deletions(-)
src/dict/main.c | 6 ++++--
diffs (18 lines):
diff -r 75cd2727f4e3 -r 645ea17b4950 src/dict/main.c
--- a/src/dict/main.c Sun Oct 05 14:07:11 2008 +0300
+++ b/src/dict/main.c Sun Oct 05 14:22:28 2008 +0300
@@ -74,10 +74,12 @@ static void main_init(void)
/* If master dies, the log fd gets closed and we'll quit */
log_io = io_add(STDERR_FILENO, IO_ERROR, log_error_callback, NULL);
- dict_drivers_register_all();
-
modules = module_dir_load(DICT_MODULE_DIR, NULL, TRUE, version);
module_dir_init(modules);
+
+ /* Register only after loading modules. They may contain SQL drivers,
+ which we'll need to register. */
+ dict_drivers_register_all();
path = getenv("DICT_LISTEN_FROM_FD");
fd = path == NULL ? -1 : DICT_MASTER_LISTENER_FD;
More information about the dovecot-cvs
mailing list