/* We used to wait for all threads to exit. Fuck that. The only thing important...
[citadel.git] / citadel / threads.c
index b0856bf2277e50afd8d298f0e9fd4a4e19dc0d44..21f585cdae75671707f0adcb33684f7ac30cb3cf 100644 (file)
@@ -53,7 +53,6 @@ int try_critical_section(int which_one)
         * transaction; this could lead to deadlock.
         */
        if (    (which_one != S_FLOORCACHE)
-               && (which_one != S_RPLIST)
        ) {
                cdb_check_handles();
        }
@@ -71,7 +70,6 @@ void begin_critical_section(int which_one)
         * transaction; this could lead to deadlock.
         */
        if (    (which_one != S_FLOORCACHE)
-               && (which_one != S_RPLIST)
        ) {
                cdb_check_handles();
        }
@@ -137,7 +135,6 @@ void CtdlThreadCreate(void *(*start_routine)(void*))
 
 
 void InitializeMasterTSD(void) {
-       TRACE;
        memset(&masterTSD, 0, sizeof(struct thread_tsd));
 }
 
@@ -170,6 +167,10 @@ void go_threading(void)
        CtdlShutdownServiceHooks();             /* close all listener sockets to prevent new connections */
        PerformSessionHooks(EVT_SHUTDOWN);      /* run any registered shutdown hooks */
 
+       /* We used to wait for all threads to exit.  Fuck that.  The only thing important is that the databases are
+        * cleanly unmounted.  After that, exit the whole program.
+        */
+#if 0
        int countdown = 30;
        while ( (num_workers > 0) && (countdown-- > 0)) {
                syslog(LOG_DEBUG, "Waiting %d seconds for %d worker threads to exit",
@@ -177,4 +178,6 @@ void go_threading(void)
                );
                usleep(1000000);
        }
+#endif
+
 }