[dovecot-cvs] dovecot/src/master auth-process.c, 1.95.2.2, 1.95.2.3 auth-process.h, 1.9, 1.9.2.1 login-process.c, 1.73.2.16, 1.73.2.17
tss at dovecot.org
tss at dovecot.org
Thu Feb 15 13:09:08 UTC 2007
Update of /var/lib/cvs/dovecot/src/master
In directory talvi:/tmp/cvs-serv23355
Modified Files:
Tag: branch_1_0
auth-process.c auth-process.h login-process.c
Log Message:
Start auth processes immediately at startup, not after one second delay.
Don't try to start any login processes before at least one auth process has
sent back a handshake.
Index: auth-process.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/master/auth-process.c,v
retrieving revision 1.95.2.2
retrieving revision 1.95.2.3
diff -u -d -r1.95.2.2 -r1.95.2.3
--- auth-process.c 1 Jul 2006 21:19:36 -0000 1.95.2.2
+++ auth-process.c 15 Feb 2007 13:08:35 -0000 1.95.2.3
@@ -54,6 +54,8 @@
unsigned int in_auth_reply:1;
};
+bool have_initialized_auth_processes = FALSE;
+
static struct timeout *to;
static unsigned int auth_tag;
static struct auth_process_group *process_groups;
@@ -166,6 +168,8 @@
process->pid = pid;
process->initialized = TRUE;
+
+ have_initialized_auth_processes = TRUE;
return TRUE;
}
@@ -773,6 +777,8 @@
{
process_groups = NULL;
to = timeout_add(1000, auth_processes_start_missing, NULL);
+
+ auth_processes_start_missing(NULL);
}
void auth_processes_deinit(void)
Index: auth-process.h
===================================================================
RCS file: /var/lib/cvs/dovecot/src/master/auth-process.h,v
retrieving revision 1.9
retrieving revision 1.9.2.1
diff -u -d -r1.9 -r1.9.2.1
--- auth-process.h 13 Oct 2004 16:38:35 -0000 1.9
+++ auth-process.h 15 Feb 2007 13:08:35 -0000 1.9.2.1
@@ -1,6 +1,8 @@
#ifndef __AUTH_PROCESS_H
#define __AUTH_PROCESS_H
+extern bool have_initialized_auth_processes;
+
void auth_master_callback(const char *user, const char *const *args,
void *context);
Index: login-process.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/master/login-process.c,v
retrieving revision 1.73.2.16
retrieving revision 1.73.2.17
diff -u -d -r1.73.2.16 -r1.73.2.17
--- login-process.c 26 Jan 2007 13:58:37 -0000 1.73.2.16
+++ login-process.c 15 Feb 2007 13:08:35 -0000 1.73.2.17
@@ -795,6 +795,12 @@
{
struct login_group *group;
+ if (!have_initialized_auth_processes) {
+ /* don't create login processes before at least one auth
+ process has finished initializing */
+ return;
+ }
+
if (login_groups == NULL)
login_process_groups_create();
More information about the dovecot-cvs
mailing list