summaryrefslogtreecommitdiff
path: root/src/modules/m_spanningtree.cpp
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2006-10-05 08:08:31 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2006-10-05 08:08:31 +0000
commit38a6bca73ce34091f0f456eb866e9cf9452d89c7 (patch)
treee2107e2bff6609bc017ab7f1ac6c9a899fe3af9b /src/modules/m_spanningtree.cpp
parentef703c9e8674cffae41460bd16003f432e3bbd2e (diff)
Add <options:announcets> to output the "TS for #chan changed from 1111 to 2222".
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5417 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/modules/m_spanningtree.cpp')
-rw-r--r--src/modules/m_spanningtree.cpp8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/modules/m_spanningtree.cpp b/src/modules/m_spanningtree.cpp
index 53f5d2909..4138d3827 100644
--- a/src/modules/m_spanningtree.cpp
+++ b/src/modules/m_spanningtree.cpp
@@ -114,6 +114,8 @@ void ReadConfiguration(bool rebind);
bool FlatLinks;
/* Hide U-Lined servers in /MAP and /LINKS */
bool HideULines;
+/* Announce TS changes to channels on merge */
+bool AnnounceTSChange;
std::vector<std::string> ValidIPs;
@@ -1606,7 +1608,10 @@ class TreeSocket : public InspSocket
if (chan)
chan->age = TS;
- /* XXX: Lower the TS here */
+ /* Lower the TS here */
+ if (AnnounceTSChange && chan)
+ chan->WriteChannelWithServ(Instance->Config->ServerName,
+ "TS for %s changed from %lu to %lu", chan->name, ourTS, TS);
ourTS = TS;
param_list.push_back(channel);
@@ -3753,6 +3758,7 @@ void ReadConfiguration(bool rebind)
}
FlatLinks = Conf->ReadFlag("options","flatlinks",0);
HideULines = Conf->ReadFlag("options","hideulines",0);
+ AnnounceTSChange = Conf->ReadFlag("options","announcets",0);
LinkBlocks.clear();
ValidIPs.clear();
for (int j =0; j < Conf->Enumerate("link"); j++)