Added BBS.pm to start allowing BBSes to send mail into the cluster
[spider.git] / perl / cluster.pl
index 8b45e2bd65d805d7fc411650b387a586199d103f..0ed98e55b39ddd33926ec6dbcd8e3aa670b080f2 100755 (executable)
@@ -68,7 +68,7 @@ package main;
 
 @inqueue = ();                                 # the main input queue, an array of hashes
 $systime = 0;                                  # the time now (in seconds)
-$version = "1.34";                             # the version no of the software
+$version = "1.35";                             # the version no of the software
 $starttime = 0;                 # the starting time of the cluster   
 $lockfn = "cluster.lock";       # lock file name
       
@@ -148,6 +148,7 @@ sub rec
                # create the channel
                $dxchan = DXCommandmode->new($call, $conn, $user) if ($user->sort eq 'U');
                $dxchan = DXProt->new($call, $conn, $user) if ($user->sort eq 'A');
+               $dxchan = BBS->new($call, $conn, $user) if ($user->sort eq 'B');
                die "Invalid sort of user on $call = $sort" if !$dxchan;
        }
        
@@ -178,9 +179,6 @@ sub cease
        };
        dbg('local', "Local::finish error $@") if $@;
 
-       # close all databases
-       DXDb::closeall;
-       
        # disconnect users
        foreach $dxchan (DXChannel->get_all()) {
                next if $dxchan->is_ak1a;
@@ -211,6 +209,10 @@ sub cease
        Msg->event_loop(1, 0.05);
        Msg->event_loop(1, 0.05);
        DXUser::finish();
+
+       # close all databases
+       DXDb::closeall;
+       
        dbg('chan', "DXSpider version $version ended");
        Log('cluster', "DXSpider V$version stopped");
        dbgclose();