mirror of
https://github.com/unrealircd/unrealircd.git
synced 2026-07-10 08:23:13 +02:00
Fix duplicate user@host in away-notify and account-notify, reported by grawity (#4153).
This commit is contained in:
@@ -117,8 +117,7 @@ int n, wasaway = 0;
|
||||
sendto_serv_butone_token(cptr, parv[0], MSG_AWAY, TOK_AWAY, "");
|
||||
hash_check_watch(cptr, RPL_NOTAWAY);
|
||||
|
||||
sendto_common_channels_local_butone(sptr, PROTO_AWAY_NOTIFY, ":%s!%s@%s AWAY",
|
||||
sptr->name, sptr->user->username, GetHost(sptr));
|
||||
sendto_common_channels_local_butone(sptr, PROTO_AWAY_NOTIFY, ":%s AWAY", sptr->name);
|
||||
}
|
||||
/* hope this works XX */
|
||||
if (MyConnect(sptr))
|
||||
@@ -172,8 +171,7 @@ int n, wasaway = 0;
|
||||
sendto_one(sptr, rpl_str(RPL_NOWAWAY), me.name, parv[0]);
|
||||
|
||||
hash_check_watch(cptr, wasaway ? RPL_REAWAY : RPL_GONEAWAY);
|
||||
sendto_common_channels_local_butone(sptr, PROTO_AWAY_NOTIFY, ":%s!%s@%s AWAY :%s",
|
||||
sptr->name, sptr->user->username, GetHost(sptr), away);
|
||||
sendto_common_channels_local_butone(sptr, PROTO_AWAY_NOTIFY, ":%s AWAY :%s", sptr->name, away);
|
||||
|
||||
RunHook2(HOOKTYPE_AWAY, sptr, away);
|
||||
return 0;
|
||||
|
||||
@@ -516,8 +516,8 @@ char *xtok = show_change ? TOK_SVS2MODE : TOK_SVSMODE;
|
||||
if (parv[3])
|
||||
{
|
||||
strlcpy(acptr->user->svid, parv[3], sizeof(acptr->user->svid));
|
||||
sendto_common_channels_local_butone(acptr, PROTO_ACCOUNT_NOTIFY, ":%s!%s@%s ACCOUNT %s",
|
||||
acptr->name, acptr->user->username, GetHost(acptr),
|
||||
sendto_common_channels_local_butone(acptr, PROTO_ACCOUNT_NOTIFY, ":%s ACCOUNT %s",
|
||||
acptr->name,
|
||||
!isdigit(*acptr->user->svid) ? acptr->user->svid : "*");
|
||||
}
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user