X-Git-Url: https://arthur.barton.de/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Fngircd%2Fparse.c;h=e5eaa6ee3ff9ad6771f13668664fe1c3b5b6ead8;hb=f8f8a9a04146fb7a4e1570ce0474ea86806879ed;hp=c92da4d2aa76b21d96bbc3dd9e2bd767c91b4190;hpb=15dfdaac823c5927b096b2980753a6198a6a7741;p=ngircd-alex.git diff --git a/src/ngircd/parse.c b/src/ngircd/parse.c index c92da4d2..e5eaa6ee 100644 --- a/src/ngircd/parse.c +++ b/src/ngircd/parse.c @@ -1,6 +1,6 @@ /* * ngIRCd -- The Next Generation IRC Daemon - * Copyright (c)2001-2010 Alexander Barton (alex@barton.de) + * Copyright (c)2001-2013 Alexander Barton (alex@barton.de) and Contributors. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -515,11 +515,11 @@ Handle_Request( CONN_ID Idx, REQUEST *Req ) if (!(client_type & cmd->type)) { if (client_type == CLIENT_USER && cmd->type & CLIENT_SERVER) - return IRC_WriteStrClient(client, + return IRC_WriteErrClient(client, ERR_NOTREGISTEREDSERVER_MSG, Client_ID(client)); else - return IRC_WriteStrClient(client, + return IRC_WriteErrClient(client, ERR_NOTREGISTERED_MSG, Client_ID(client)); } @@ -549,11 +549,10 @@ Handle_Request( CONN_ID Idx, REQUEST *Req ) Req->argc == 1 ? "parameter" : "parameters", Req->prefix ? "" : " no" ); - if (Client_Type(client) != CLIENT_SERVER) { - result = IRC_WriteStrClient(client, ERR_UNKNOWNCOMMAND_MSG, + if (Client_Type(client) != CLIENT_SERVER) + result = IRC_WriteErrClient(client, ERR_UNKNOWNCOMMAND_MSG, Client_ID(client), Req->command); - Conn_SetPenalty(Idx, 1); - } + return result; } /* Handle_Request */