diff options
author | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2004-04-12 11:25:47 +0000 |
---|---|---|
committer | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2004-04-12 11:25:47 +0000 |
commit | 4423aaf010ce6d30ddc19989371a861c6a17c825 (patch) | |
tree | f8dd9f125f5d94973ba8bcada27aef240d012028 | |
parent | 5469a91c7f9cbd08cb2f458015f02606abc8154b (diff) |
'K' token fixes
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@560 e03df62e-2008-0410-955e-edbf42e46eb7
-rw-r--r-- | src/inspircd.cpp | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/inspircd.cpp b/src/inspircd.cpp index dd79bd0a1..607c79b83 100644 --- a/src/inspircd.cpp +++ b/src/inspircd.cpp @@ -3915,7 +3915,7 @@ void handle_kill(char **parameters, int pcnt, userrec *user) { // remote kill WriteOpers("*** Remote kill: %s!%s@%s (%s)",user->nick,u->nick,u->ident,u->host,parameters[1]); - sprintf(killreason,"[%s] Killed (%s (%s))",u->server,user->nick,parameters[1]); + sprintf(killreason,"[%s] Killed (%s (%s))",ServerName,user->nick,parameters[1]); WriteCommonExcept(u,"QUIT :%s",killreason); // K token must go to ALL servers!!! char buffer[MAXBUF]; @@ -6272,6 +6272,7 @@ void handle_K(char token,char* params,serverrec* source,serverrec* reply, char* char* src = strtok(params," "); char* nick = strtok(NULL," :"); char* reason = strtok(NULL,"\r\n"); + char kreason[MAXBUF]; reason++; userrec* u = Find(nick); @@ -6279,10 +6280,10 @@ void handle_K(char token,char* params,serverrec* source,serverrec* reply, char* if ((user) && (u)) { - WriteTo(user, u, "KILL %s :%s!%s!%s!%s (%s)", u->nick, source->name,ServerName,user->dhost,user->nick,reason); + WriteTo(user, u, "KILL %s :%s!%s!%s!%s (%s)", u->nick, ServerName, reply->name, user->dhost,user->nick,reason); WriteOpers("*** Remote kill from %s by %s: %s!%s@%s (%s)",source->name,user->nick,u->nick,u->ident,u->host,reason); - snprintf(reason,MAXQUIT,"[%s] Killed (%s (%s))",source->name,user->nick,reason); - kill_link(u,reason); + snprintf(kreason,MAXBUF,"[%s] Killed (%s (%s))",reply->name,user->nick,reason); + kill_link(u,kreason); } } |