summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2006-08-27 00:53:50 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2006-08-27 00:53:50 +0000
commit89161fbd869aa423163bc18c2eb7c6ec2a581b9c (patch)
treef6b587d3dc6a53d4d3378b902e51b29714c169dd
parent439843a2f3e57632924a3e77a7bb15f19a07ee7d (diff)
Extra sanity checks
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5029 e03df62e-2008-0410-955e-edbf42e46eb7
-rw-r--r--src/modules/m_spanningtree.cpp14
1 files changed, 9 insertions, 5 deletions
diff --git a/src/modules/m_spanningtree.cpp b/src/modules/m_spanningtree.cpp
index 78a1ebb04..5266d8240 100644
--- a/src/modules/m_spanningtree.cpp
+++ b/src/modules/m_spanningtree.cpp
@@ -3170,7 +3170,8 @@ bool DoOneToAllButSenderRaw(std::string data, std::string omit, std::string pref
if ((Route) && (Route->GetSocket()) && (Route->GetName() != omit) && (omitroute != Route))
{
TreeSocket* Sock = Route->GetSocket();
- Sock->WriteLine(data);
+ if (Sock)
+ Sock->WriteLine(data);
}
}
return true;
@@ -3196,7 +3197,8 @@ bool DoOneToAllButSender(std::string prefix, std::string command, std::deque<std
if ((Route) && (Route->GetSocket()) && (Route->GetName() != omit) && (omitroute != Route))
{
TreeSocket* Sock = Route->GetSocket();
- Sock->WriteLine(FullLine);
+ if (Sock)
+ Sock->WriteLine(FullLine);
}
}
return true;
@@ -3217,7 +3219,8 @@ bool DoOneToMany(std::string prefix, std::string command, std::deque<std::string
if (Route && Route->GetSocket())
{
TreeSocket* Sock = Route->GetSocket();
- Sock->WriteLine(FullLine);
+ if (Sock)
+ Sock->WriteLine(FullLine);
}
}
return true;
@@ -3251,13 +3254,14 @@ bool DoOneToOne(std::string prefix, std::string command, std::deque<std::string>
if (Route && Route->GetSocket())
{
TreeSocket* Sock = Route->GetSocket();
- Sock->WriteLine(FullLine);
+ if (Sock)
+ Sock->WriteLine(FullLine);
}
return true;
}
else
{
- return true;
+ return false;
}
}