make camel_shutdown() an atexit handler again
authorJeffrey Stedfast <fejj@src.gnome.org>
Fri, 18 Jun 2004 21:11:18 +0000 (21:11 +0000)
committerJeffrey Stedfast <fejj@src.gnome.org>
Fri, 18 Jun 2004 21:11:18 +0000 (21:11 +0000)
camel/ChangeLog
camel/camel.c
camel/camel.h

index 40d1292..0b1745b 100644 (file)
@@ -2,8 +2,6 @@
 
        * camel.c (camel_shutdown): Call camel_mime_utils_shutdown() and
        camel_operation_shutdown().
-       (camel_init): Don't register camel_shutdown() as an atexit
-       handler.
 
        * camel-operation.c (camel_operation_shutdown): New function.
 
index a3f4961..f370d89 100644 (file)
@@ -43,7 +43,7 @@
 
 static int initialised = FALSE;
 
-void
+static void
 camel_shutdown (void)
 {
        void camel_operation_shutdown (void);
@@ -123,6 +123,8 @@ camel_init (const char *configdir, gboolean nss_init)
        
        camel_object_unref (certdb);
        
+       g_atexit (camel_shutdown);
+       
        initialised = TRUE;
        
        return 0;
index edc1e31..90511d6 100644 (file)
@@ -88,7 +88,6 @@ extern "C" {
 #include <camel/camel-string-utils.h>
 
 int camel_init (const char *certdb_dir, gboolean nss_init);
-void camel_shutdown (void);
 
 #ifdef __cplusplus
 }