[svn] Target left IRC (more friendly error message if a UID

cannot be found) for /invite.
This commit is contained in:
jilles 2007-05-06 07:46:45 -07:00
parent 1d3e262e40
commit 0482ebf7b6
3 changed files with 21 additions and 6 deletions

View File

@ -1,3 +1,13 @@
jilles 2007/05/02 19:56:40 UTC (20070502-3436)
Log:
Remove emptyline craq because it leaks memory on /rehash motd etc.
from ratbox 2.2 (anfl/Androsyn)
Changes: Modified:
+6 -14 trunk/src/cache.c (File Modified)
jilles 2007/04/28 23:47:25 UTC (20070428-3434) jilles 2007/04/28 23:47:25 UTC (20070428-3434)
Log: Log:
Merge old trunk r2767: Merge old trunk r2767:

View File

@ -1 +1 @@
#define SERNO "20070428-3434" #define SERNO "20070502-3436"

View File

@ -21,7 +21,7 @@
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
* USA * USA
* *
* $Id: m_invite.c 3259 2007-03-15 18:09:08Z jilles $ * $Id: m_invite.c 3438 2007-05-06 14:46:45Z jilles $
*/ */
#include "stdinc.h" #include "stdinc.h"
@ -48,7 +48,7 @@ struct Message invite_msgtab = {
{mg_unreg, {m_invite, 3}, {m_invite, 3}, mg_ignore, mg_ignore, {m_invite, 3}} {mg_unreg, {m_invite, 3}, {m_invite, 3}, mg_ignore, mg_ignore, {m_invite, 3}}
}; };
mapi_clist_av1 invite_clist[] = { &invite_msgtab, NULL }; mapi_clist_av1 invite_clist[] = { &invite_msgtab, NULL };
DECLARE_MODULE_AV1(invite, NULL, NULL, invite_clist, NULL, NULL, "$Revision: 3259 $"); DECLARE_MODULE_AV1(invite, NULL, NULL, invite_clist, NULL, NULL, "$Revision: 3438 $");
static void add_invite(struct Channel *, struct Client *); static void add_invite(struct Channel *, struct Client *);
@ -70,9 +70,14 @@ m_invite(struct Client *client_p, struct Client *source_p, int parc, const char
if((target_p = find_person(parv[1])) == NULL) if((target_p = find_person(parv[1])) == NULL)
{ {
sendto_one_numeric(source_p, ERR_NOSUCHNICK, if(!MyClient(source_p) && IsDigit(parv[1][0]))
form_str(ERR_NOSUCHNICK), sendto_one_numeric(source_p, ERR_NOSUCHNICK,
IsDigit(parv[1][0]) ? "*" : parv[1]); "* :Target left IRC. Failed to invite to %s",
parv[2]);
else
sendto_one_numeric(source_p, ERR_NOSUCHNICK,
form_str(ERR_NOSUCHNICK),
parv[1]);
return 0; return 0;
} }