Replace parv[0] with source_p->name.
This commit is contained in:
parent
0a849a8fa9
commit
3dfaa67120
8 changed files with 18 additions and 18 deletions
|
@ -56,7 +56,7 @@ m_mkpasswd(struct Client *client_p, struct Client *source_p, int parc, const cha
|
||||||
if((last_used + ConfigFileEntry.pace_wait) > rb_current_time())
|
if((last_used + ConfigFileEntry.pace_wait) > rb_current_time())
|
||||||
{
|
{
|
||||||
/* safe enough to give this on a local connect only */
|
/* safe enough to give this on a local connect only */
|
||||||
sendto_one(source_p, form_str(RPL_LOAD2HI), me.name, parv[0], "MKPASSWD");
|
sendto_one(source_p, form_str(RPL_LOAD2HI), me.name, source_p->name, "MKPASSWD");
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
@ -85,7 +85,7 @@ m_mkpasswd(struct Client *client_p, struct Client *source_p, int parc, const cha
|
||||||
}
|
}
|
||||||
|
|
||||||
if(parc == 1)
|
if(parc == 1)
|
||||||
sendto_one(source_p, form_str(ERR_NEEDMOREPARAMS), me.name, parv[0], "MKPASSWD");
|
sendto_one(source_p, form_str(ERR_NEEDMOREPARAMS), me.name, source_p->name, "MKPASSWD");
|
||||||
else
|
else
|
||||||
sendto_one_notice(source_p, ":Encryption for [%s]: %s",
|
sendto_one_notice(source_p, ":Encryption for [%s]: %s",
|
||||||
parv[1], rb_crypt(parv[1],
|
parv[1], rb_crypt(parv[1],
|
||||||
|
@ -127,7 +127,7 @@ mo_mkpasswd(struct Client *client_p, struct Client *source_p, int parc, const ch
|
||||||
}
|
}
|
||||||
|
|
||||||
if(parc == 1)
|
if(parc == 1)
|
||||||
sendto_one(source_p, form_str(ERR_NEEDMOREPARAMS), me.name, parv[0], "MKPASSWD");
|
sendto_one(source_p, form_str(ERR_NEEDMOREPARAMS), me.name, source_p->name, "MKPASSWD");
|
||||||
else
|
else
|
||||||
sendto_one_notice(source_p, ":Encryption for [%s]: %s",
|
sendto_one_notice(source_p, ":Encryption for [%s]: %s",
|
||||||
parv[1], rb_crypt(parv[1], is_md5 ? make_md5_salt() : make_salt()));
|
parv[1], rb_crypt(parv[1], is_md5 ? make_md5_salt() : make_salt()));
|
||||||
|
|
|
@ -73,7 +73,7 @@ mo_okick(struct Client *client_p, struct Client *source_p, int parc, const char
|
||||||
|
|
||||||
if(*parv[2] == '\0')
|
if(*parv[2] == '\0')
|
||||||
{
|
{
|
||||||
sendto_one(source_p, form_str(ERR_NEEDMOREPARAMS), me.name, parv[0], "KICK");
|
sendto_one(source_p, form_str(ERR_NEEDMOREPARAMS), me.name, source_p->name, "KICK");
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -108,14 +108,14 @@ mo_okick(struct Client *client_p, struct Client *source_p, int parc, const char
|
||||||
|
|
||||||
if((target_p = find_client(user)) == NULL)
|
if((target_p = find_client(user)) == NULL)
|
||||||
{
|
{
|
||||||
sendto_one(source_p, form_str(ERR_NOSUCHNICK), me.name, parv[0], user);
|
sendto_one(source_p, form_str(ERR_NOSUCHNICK), me.name, source_p->name, user);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
if((msptr = find_channel_membership(chptr, target_p)) == NULL)
|
if((msptr = find_channel_membership(chptr, target_p)) == NULL)
|
||||||
{
|
{
|
||||||
sendto_one(source_p, form_str(ERR_USERNOTINCHANNEL),
|
sendto_one(source_p, form_str(ERR_USERNOTINCHANNEL),
|
||||||
me.name, parv[0], parv[1], parv[2]);
|
me.name, source_p->name, parv[1], parv[2]);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -126,7 +126,7 @@ mo_kill(struct Client *client_p, struct Client *source_p, int parc, const char *
|
||||||
sendto_realops_snomask(SNO_GENERAL, L_ALL,
|
sendto_realops_snomask(SNO_GENERAL, L_ALL,
|
||||||
"Received KILL message for %s!%s@%s. From %s Path: %s (%s)",
|
"Received KILL message for %s!%s@%s. From %s Path: %s (%s)",
|
||||||
target_p->name, target_p->username, target_p->orighost,
|
target_p->name, target_p->username, target_p->orighost,
|
||||||
parv[0], me.name, reason);
|
source_p->name, me.name, reason);
|
||||||
|
|
||||||
ilog(L_KILL, "%c %s %s!%s@%s %s %s",
|
ilog(L_KILL, "%c %s %s!%s@%s %s %s",
|
||||||
MyConnect(target_p) ? 'L' : 'G', get_oper_name(source_p),
|
MyConnect(target_p) ? 'L' : 'G', get_oper_name(source_p),
|
||||||
|
@ -245,7 +245,7 @@ ms_kill(struct Client *client_p, struct Client *source_p, int parc, const char *
|
||||||
{
|
{
|
||||||
sendto_realops_snomask(IsService(source_p) ? SNO_SKILL : SNO_GENERAL, L_ALL,
|
sendto_realops_snomask(IsService(source_p) ? SNO_SKILL : SNO_GENERAL, L_ALL,
|
||||||
"Received KILL message for %s!%s@%s. From %s Path: %s!%s!%s!%s %s",
|
"Received KILL message for %s!%s@%s. From %s Path: %s!%s!%s!%s %s",
|
||||||
target_p->name, target_p->username, target_p->orighost, parv[0],
|
target_p->name, target_p->username, target_p->orighost, source_p->name,
|
||||||
source_p->servptr->name, source_p->host, source_p->username,
|
source_p->servptr->name, source_p->host, source_p->username,
|
||||||
source_p->name, reason);
|
source_p->name, reason);
|
||||||
|
|
||||||
|
@ -259,7 +259,7 @@ ms_kill(struct Client *client_p, struct Client *source_p, int parc, const char *
|
||||||
sendto_realops_snomask(SNO_SKILL, L_ALL,
|
sendto_realops_snomask(SNO_SKILL, L_ALL,
|
||||||
"Received KILL message for %s!%s@%s. From %s %s",
|
"Received KILL message for %s!%s@%s. From %s %s",
|
||||||
target_p->name, target_p->username, target_p->orighost,
|
target_p->name, target_p->username, target_p->orighost,
|
||||||
parv[0], reason);
|
source_p->name, reason);
|
||||||
|
|
||||||
ilog(L_KILL, "S %s %s!%s@%s %s %s",
|
ilog(L_KILL, "S %s %s!%s@%s %s %s",
|
||||||
source_p->name, target_p->name, target_p->username,
|
source_p->name, target_p->name, target_p->username,
|
||||||
|
|
|
@ -145,7 +145,7 @@ mr_nick(struct Client *client_p, struct Client *source_p, int parc, const char *
|
||||||
if(!clean_nick(nick, 1))
|
if(!clean_nick(nick, 1))
|
||||||
{
|
{
|
||||||
sendto_one(source_p, form_str(ERR_ERRONEUSNICKNAME),
|
sendto_one(source_p, form_str(ERR_ERRONEUSNICKNAME),
|
||||||
me.name, EmptyString(parv[0]) ? "*" : parv[0], parv[1]);
|
me.name, EmptyString(source_p->name) ? "*" : source_p->name, parv[1]);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -208,7 +208,7 @@ m_nick(struct Client *client_p, struct Client *source_p, int parc, const char *p
|
||||||
/* check the nickname is ok */
|
/* check the nickname is ok */
|
||||||
if(!clean_nick(nick, 1))
|
if(!clean_nick(nick, 1))
|
||||||
{
|
{
|
||||||
sendto_one(source_p, form_str(ERR_ERRONEUSNICKNAME), me.name, parv[0], nick);
|
sendto_one(source_p, form_str(ERR_ERRONEUSNICKNAME), me.name, source_p->name, nick);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -245,7 +245,7 @@ m_nick(struct Client *client_p, struct Client *source_p, int parc, const char *p
|
||||||
change_local_nick(client_p, source_p, nick, 1);
|
change_local_nick(client_p, source_p, nick, 1);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
sendto_one(source_p, form_str(ERR_NICKNAMEINUSE), me.name, parv[0], nick);
|
sendto_one(source_p, form_str(ERR_NICKNAMEINUSE), me.name, source_p->name, nick);
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
@ -389,7 +389,7 @@ ms_uid(struct Client *client_p, struct Client *source_p, int parc, const char *p
|
||||||
{
|
{
|
||||||
char *s = LOCAL_COPY(parv[9]);
|
char *s = LOCAL_COPY(parv[9]);
|
||||||
sendto_realops_snomask(SNO_GENERAL, L_ALL, "Long realname from server %s for %s",
|
sendto_realops_snomask(SNO_GENERAL, L_ALL, "Long realname from server %s for %s",
|
||||||
parv[0], parv[1]);
|
source_p->name, parv[1]);
|
||||||
s[REALLEN] = '\0';
|
s[REALLEN] = '\0';
|
||||||
parv[9] = s;
|
parv[9] = s;
|
||||||
}
|
}
|
||||||
|
@ -490,7 +490,7 @@ ms_euid(struct Client *client_p, struct Client *source_p, int parc, const char *
|
||||||
{
|
{
|
||||||
char *s = LOCAL_COPY(parv[11]);
|
char *s = LOCAL_COPY(parv[11]);
|
||||||
sendto_realops_snomask(SNO_GENERAL, L_ALL, "Long realname from server %s for %s",
|
sendto_realops_snomask(SNO_GENERAL, L_ALL, "Long realname from server %s for %s",
|
||||||
parv[0], parv[1]);
|
source_p->name, parv[1]);
|
||||||
s[REALLEN] = '\0';
|
s[REALLEN] = '\0';
|
||||||
parv[11] = s;
|
parv[11] = s;
|
||||||
}
|
}
|
||||||
|
|
|
@ -148,7 +148,7 @@ ms_squit(struct Client *client_p, struct Client *source_p, int parc, const char
|
||||||
":%s WALLOPS :Remote SQUIT %s from %s (%s)",
|
":%s WALLOPS :Remote SQUIT %s from %s (%s)",
|
||||||
me.id, target_p->name, source_p->name, comment);
|
me.id, target_p->name, source_p->name, comment);
|
||||||
|
|
||||||
ilog(L_SERVER, "SQUIT From %s : %s (%s)", parv[0], target_p->name, comment);
|
ilog(L_SERVER, "SQUIT From %s : %s (%s)", source_p->name, target_p->name, comment);
|
||||||
}
|
}
|
||||||
exit_client(client_p, target_p, source_p, comment);
|
exit_client(client_p, target_p, source_p, comment);
|
||||||
return 0;
|
return 0;
|
||||||
|
|
|
@ -129,7 +129,7 @@ mo_connect(struct Client *client_p, struct Client *source_p, int parc, const cha
|
||||||
* Notify all operators about remote connect requests
|
* Notify all operators about remote connect requests
|
||||||
*/
|
*/
|
||||||
|
|
||||||
ilog(L_SERVER, "CONNECT From %s : %s %s", parv[0], parv[1], parc > 2 ? parv[2] : "");
|
ilog(L_SERVER, "CONNECT From %s : %s %s", source_p->name, parv[1], parc > 2 ? parv[2] : "");
|
||||||
|
|
||||||
server_p->port = port;
|
server_p->port = port;
|
||||||
/*
|
/*
|
||||||
|
|
|
@ -127,7 +127,7 @@ mr_pong(struct Client *client_p, struct Client *source_p, int parc, const char *
|
||||||
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
sendto_one(source_p, form_str(ERR_NOORIGIN), me.name, parv[0]);
|
sendto_one(source_p, form_str(ERR_NOORIGIN), me.name, source_p->name);
|
||||||
|
|
||||||
source_p->flags &= ~FLAGS_PINGSENT;
|
source_p->flags &= ~FLAGS_PINGSENT;
|
||||||
|
|
||||||
|
|
|
@ -63,7 +63,7 @@ m_userhost(struct Client *client_p, struct Client *source_p, int parc, const cha
|
||||||
int cur_len;
|
int cur_len;
|
||||||
int rl;
|
int rl;
|
||||||
|
|
||||||
cur_len = rb_sprintf(buf, form_str(RPL_USERHOST), me.name, parv[0], "");
|
cur_len = rb_sprintf(buf, form_str(RPL_USERHOST), me.name, source_p->name, "");
|
||||||
t = buf + cur_len;
|
t = buf + cur_len;
|
||||||
|
|
||||||
for (i = 1; i <= 5; i++)
|
for (i = 1; i <= 5; i++)
|
||||||
|
|
Loading…
Reference in a new issue