summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorspecial <special@e03df62e-2008-0410-955e-edbf42e46eb7>2006-09-28 19:05:35 +0000
committerspecial <special@e03df62e-2008-0410-955e-edbf42e46eb7>2006-09-28 19:05:35 +0000
commite4319d0d601181956664388a2828e2782cb50ff8 (patch)
tree32fb7276b62ed944ba404442cbe1c2b7ea9ca135
parenta753cc1ec3af9c2d6095f313c233050585f96f98 (diff)
Fixed another segfault in m_spanningtree's FJOIN (forgot to check if the channel existed before setting its TS)
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5354 e03df62e-2008-0410-955e-edbf42e46eb7
-rw-r--r--src/modules/m_spanningtree.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/modules/m_spanningtree.cpp b/src/modules/m_spanningtree.cpp
index a1df169e1..33b3e2bdb 100644
--- a/src/modules/m_spanningtree.cpp
+++ b/src/modules/m_spanningtree.cpp
@@ -1545,9 +1545,7 @@ class TreeSocket : public InspSocket
time_t ourTS = time(NULL)+600;
chanrec* us = this->Instance->FindChan(channel);
if (us)
- {
ourTS = us->age;
- }
/* XXX: PAY ATTENTION:
* In 1.1, if they have the newer channel, we immediately clear
@@ -1560,7 +1558,8 @@ class TreeSocket : public InspSocket
{
Instance->Log(DEBUG,"FJOIN detected, our TS=%lu, their TS=%lu",ourTS,TS);
std::deque<std::string> param_list;
- us->age = TS;
+ if (us)
+ us->age = TS;
ourTS = TS;
param_list.push_back(chan->name);
Instance->Log(DEBUG,"REMOVE ALL STATUS MODES FROM OUR USERS *NOW*");