~ubuntu-branches/ubuntu/oneiric/inspircd/oneiric-security

« back to all changes in this revision

Viewing changes to src/modules/m_spanningtree/main.cpp

  • Committer: Bazaar Package Importer
  • Author(s): Darren Blaber
  • Date: 2008-04-21 12:51:01 UTC
  • mfrom: (1.1.2 upstream)
  • Revision ID: james.westby@ubuntu.com-20080421125101-m6lqhtn1wna8u2go
Tags: 1.1.19+dfsg-1
New upstream version

Show diffs side-by-side

added added

removed removed

Lines of Context:
46
46
        ServerInstance->AddCommand(command_rconnect);
47
47
        command_rsquit = new cmd_rsquit(ServerInstance, this, Utils);
48
48
        ServerInstance->AddCommand(command_rsquit);
49
 
        if (Utils->EnableTimeSync)
50
 
        {
51
 
                SyncTimer = new TimeSyncTimer(ServerInstance, this);
52
 
                ServerInstance->Timers->AddTimer(SyncTimer);
53
 
        }
54
 
        else
55
 
                SyncTimer = NULL;
56
 
 
57
 
        RefreshTimer = new CacheRefreshTimer(ServerInstance, Utils);
58
 
        ServerInstance->Timers->AddTimer(RefreshTimer);
59
49
}
60
50
 
61
51
void ModuleSpanningTree::ShowLinks(TreeServer* Current, userrec* user, int hops)
979
969
{
980
970
        AutoConnectServers(curtime);
981
971
        DoPingChecks(curtime);
 
972
        if (curtime % 60 == 0)
 
973
        {
 
974
                if (Utils->EnableTimeSync)
 
975
                        BroadcastTimeSync();
 
976
                Utils->RefreshIPCache();
 
977
        }
982
978
}
983
979
 
984
980
void ModuleSpanningTree::OnUserJoin(userrec* user, chanrec* channel, bool &silent)
1418
1414
{
1419
1415
        /* This will also free the listeners */
1420
1416
        delete Utils;
1421
 
        if (SyncTimer)
1422
 
                ServerInstance->Timers->DelTimer(SyncTimer);
1423
 
 
1424
 
        ServerInstance->Timers->DelTimer(RefreshTimer);
1425
 
 
1426
1417
        ServerInstance->DoneWithInterface("InspSocketHook");
1427
1418
}
1428
1419