punctuation is allowed.*/
ptr = Req->argv[0];
while (*ptr) {
- if (!isalnum(*ptr) &&
+ if (!isalnum((int)*ptr) &&
*ptr != '+' && *ptr != '-' &&
*ptr != '.' && *ptr != '_') {
Conn_Close(Client_Conn(Client), NULL,
}
if (target != Client) {
- Client_Destroy(target, "Got QUIT command.",
+ Client_Destroy(target, "Got QUIT command",
Req->argc == 1 ? quitmsg : NULL, true);
return CONNECTED;
} else {
- Conn_Close(Client_Conn(Client), "Got QUIT command.",
+ Conn_Close(Client_Conn(Client), "Got QUIT command",
Req->argc == 1 ? quitmsg : NULL, true);
return DISCONNECTED;
}
}
/* User, Service, or not yet registered */
- Conn_Close(Client_Conn(Client), "Got QUIT command.",
+ Conn_Close(Client_Conn(Client), "Got QUIT command",
Req->argc == 1 ? quitmsg : NULL, true);
return DISCONNECTED;
if (Client_Type(Client) == CLIENT_SERVER && Conn_LastPing(conn) == 0) {
Log(LOG_INFO,
- "Synchronization with \"%s\" done (connection %d): %ld seconds [%ld users, %ld channels]",
+ "Synchronization with \"%s\" done (connection %d): %ld second%s [%ld users, %ld channels].",
Client_ID(Client), conn, time(NULL) - Conn_GetSignon(conn),
+ time(NULL) - Conn_GetSignon(conn) == 1 ? "" : "s",
Client_UserCount(), Channel_CountVisible(NULL));
Conn_UpdatePing(conn);
} else
r.argv[1] = Reason;
r.argc = 2;
- Log(LOG_ERR, "User(s) with nick \"%s\" will be disconnected: %s",
+ Log(LOG_ERR, "User(s) with nick \"%s\" will be disconnected: %s!",
Nick, Reason);
IRC_KILL(Client_ThisServer(), &r);
/* Inform all servers and users (which have to know) of the new name */
if (InformClient) {
- IRC_WriteStrClientPrefix(Target, Origin, "NICK :%s", NewNick);
+ IRC_WriteStrClientPrefix(Target, Target, "NICK :%s", NewNick);
IRC_WriteStrServersPrefix(NULL, Target, "NICK :%s", NewNick);
} else
IRC_WriteStrServersPrefix(Origin, Target, "NICK :%s", NewNick);