summaryrefslogtreecommitdiff
path: root/src/commands.cpp
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2005-04-29 15:01:13 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2005-04-29 15:01:13 +0000
commitdb11f2b24c6aeb5ab7ba4678638890bc68b1d0c1 (patch)
tree74480013c1ae951748073e505259a7d35fee8609 /src/commands.cpp
parent96bf59631c7a17d9f0e99847a33df85a279aae4d (diff)
Fixed some flood checking
added noticeall git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@1262 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/commands.cpp')
-rw-r--r--src/commands.cpp21
1 files changed, 14 insertions, 7 deletions
diff --git a/src/commands.cpp b/src/commands.cpp
index c098bbb10..610b694bc 100644
--- a/src/commands.cpp
+++ b/src/commands.cpp
@@ -1863,18 +1863,25 @@ void handle_V(char token,char* params,serverrec* source,serverrec* reply, char*
userrec* user = Find(src);
if (user)
{
- userrec* dst = Find(dest);
-
- if (dst)
+ // notice all - only issuable by a server
+ if (strcmp(dest,"*"))
{
- WriteTo(user, dst, "NOTICE %s :%s", dst->nick, text);
+ NoticeAll(user,true,"%s",text);
}
else
{
- chanrec* d = FindChan(dest);
- if (d)
+ userrec* dst = Find(dest);
+ if (dst)
{
- ChanExceptSender(d, user, "NOTICE %s :%s", d->name, text);
+ WriteTo(user, dst, "NOTICE %s :%s", dst->nick, text);
+ }
+ else
+ {
+ chanrec* d = FindChan(dest);
+ if (d)
+ {
+ ChanExceptSender(d, user, "NOTICE %s :%s", d->name, text);
+ }
}
}
}