]> granicus.if.org Git - ngircd/commitdiff
PRIVMSG/NOTICE: don't stop list processing on invalid target
authorAlexander Barton <alex@barton.de>
Mon, 16 Jan 2012 11:37:37 +0000 (12:37 +0100)
committerAlexander Barton <alex@barton.de>
Mon, 16 Jan 2012 11:37:37 +0000 (12:37 +0100)
Process further targets, even if one has been a server ID:
just skip this one with an error message and continue.

src/ngircd/irc.c

index 2b94e33ac229b44cf509277c23944034bebf5a51..5af79396ee0add0ef82f5dd8a7905ccdce912636 100644 (file)
@@ -469,11 +469,11 @@ Send_Message(CLIENT * Client, REQUEST * Req, int ForceType, bool SendErrors)
 #else
                        if (Client_Type(cl) != ForceType) {
 #endif
-                               if (!SendErrors)
-                                       return CONNECTED;
-                               return IRC_WriteStrClient(from, ERR_NOSUCHNICK_MSG,
-                                                         Client_ID(from),
-                                                         currentTarget);
+                               if (SendErrors && !IRC_WriteStrClient(
+                                   from, ERR_NOSUCHNICK_MSG,Client_ID(from),
+                                   currentTarget))
+                                       return DISCONNECTED;
+                               goto send_next_target;
                        }
 
 #ifndef STRICT_RFC