[dovecot-cvs] dovecot/src/auth auth-master-listener.c, 1.6, 1.7 auth-master-listener.h, 1.3, 1.4 main.c, 1.54, 1.55

cras at dovecot.org cras at dovecot.org
Fri Apr 14 13:22:59 EEST 2006


Update of /var/lib/cvs/dovecot/src/auth
In directory talvi:/tmp/cvs-serv38

Modified Files:
	auth-master-listener.c auth-master-listener.h main.c 
Log Message:
Deinitialization crashfixes.



Index: auth-master-listener.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/auth/auth-master-listener.c,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -d -r1.6 -r1.7
--- auth-master-listener.c	29 Jan 2006 12:14:40 -0000	1.6
+++ auth-master-listener.c	14 Apr 2006 10:22:55 -0000	1.7
@@ -55,17 +55,14 @@
 	i_free(socket);
 }
 
-void auth_master_listener_destroy(struct auth_master_listener **_listener)
+void auth_master_listener_destroy(struct auth_master_listener *listener)
 {
-        struct auth_master_listener *listener = *_listener;
 	struct auth_master_listener *const *listeners;
 	struct auth_master_listener_socket **sockets;
 	struct auth_master_connection **masters;
 	struct auth_client_connection **clients;
 	unsigned int i, count;
 
-	*_listener = NULL;
-
 	listeners = array_get(&master_listeners, &count);
 	for (i = 0; i < count; i++) {
 		if (listeners[i] == listener) {
@@ -182,6 +179,6 @@
 
 	listeners = array_get_modifyable(&master_listeners, &count);
 	for (i = count; i > 0; i--)
-		auth_master_listener_destroy(&listeners[i-1]);
+		auth_master_listener_destroy(listeners[i-1]);
 	array_free(&master_listeners);
 }

Index: auth-master-listener.h
===================================================================
RCS file: /var/lib/cvs/dovecot/src/auth/auth-master-listener.h,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- auth-master-listener.h	14 Jan 2006 18:47:20 -0000	1.3
+++ auth-master-listener.h	14 Apr 2006 10:22:55 -0000	1.4
@@ -18,7 +18,7 @@
 };
 
 struct auth_master_listener *auth_master_listener_create(struct auth *auth);
-void auth_master_listener_destroy(struct auth_master_listener **listener);
+void auth_master_listener_destroy(struct auth_master_listener *listener);
 
 void auth_master_listener_add(struct auth_master_listener *listener,
 			      int fd, const char *path,

Index: main.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/auth/main.c,v
retrieving revision 1.54
retrieving revision 1.55
diff -u -d -r1.54 -r1.55
--- main.c	26 Jan 2006 22:01:00 -0000	1.54
+++ main.c	14 Apr 2006 10:22:55 -0000	1.55
@@ -268,8 +268,6 @@
 
 static void main_deinit(void)
 {
-	auth_deinit(&auth);
-
 	if (worker_client != NULL)
 		auth_worker_client_unref(&worker_client);
 	else
@@ -278,6 +276,7 @@
         auth_worker_server_deinit();
 	auth_master_listeners_deinit();
 	auth_request_handler_deinit();
+	auth_deinit(&auth);
 	mech_deinit();
 
         password_schemes_deinit();



More information about the dovecot-cvs mailing list