summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2004-04-10 01:56:49 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2004-04-10 01:56:49 +0000
commitc0fb6e8951f77baab93a02342e4f38b7f7cd1beb (patch)
tree7031f9a0f4243ad52c9673ae360a03cbd2e58ce6
parent937ce6539ca689c1071f6fb67638e33703d6fac7 (diff)
Fixed 'N' gecos
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@486 e03df62e-2008-0410-955e-edbf42e46eb7
-rw-r--r--src/inspircd.cpp18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/inspircd.cpp b/src/inspircd.cpp
index 9484532c2..3c8a43dac 100644
--- a/src/inspircd.cpp
+++ b/src/inspircd.cpp
@@ -5148,13 +5148,13 @@ void DoSync(serverrec* serv, char* udp_host,int udp_port, long MyKey)
void handle_N(char token,char* params,serverrec* source,serverrec* reply, char* udp_host,int udp_port)
{
// %d %s %s %s %s %s %s :%s
- char g[MAXBUF];
- strcpy(g,params);
- char* gecos = g;
- while ((gecos[0] != ':') && (strlen(gecos)))
- gecos++;
- if (strlen(gecos))
- gecos++;
+ //char g[MAXBUF];
+ //strcpy(g,params);
+ //char* gecos = g;
+ //while ((gecos[0] != ':') && (strlen(gecos)))
+ // gecos++;
+ //if (strlen(gecos))
+ // gecos++;
char* tm = strtok(params," ");
char* nick = strtok(NULL," ");
char* host = strtok(NULL," ");
@@ -5162,7 +5162,7 @@ void handle_N(char token,char* params,serverrec* source,serverrec* reply, char*
char* ident = strtok(NULL," ");
char* modes = strtok(NULL," ");
char* server = strtok(NULL," :");
- char* junk = strtok(NULL,"\r\n");
+ char* gecos = strtok(NULL,"\r\n");
time_t TS = atoi(tm);
user_hash::iterator iter = clientlist.find(nick);
if (iter != clientlist.end())
@@ -5188,7 +5188,7 @@ void handle_N(char token,char* params,serverrec* source,serverrec* reply, char*
strncpy(clientlist[nick]->dhost, dhost,160);
strncpy(clientlist[nick]->server, server,256);
strncpy(clientlist[nick]->ident, ident,10); // +1 char to compensate for '~'
- //strncpy(clientlist[nick]->fullname, gecos,128);
+ strncpy(clientlist[nick]->fullname, gecos,128);
clientlist[nick]->signon = TS;
clientlist[nick]->nping = 0; // this is ignored for a remote user anyway.
clientlist[nick]->lastping = 1;