Disallow changing away status via /presence.
Allowing this desynchronizes clients and servers that do not know about this extension without good reason. If you want to allow this, change it to spit out the usual AWAY protocol.
This commit is contained in:
parent
50325a6667
commit
72d36704fc
1 changed files with 6 additions and 0 deletions
|
@ -65,6 +65,12 @@ m_presence(struct Client *client_p, struct Client *source_p, int parc, const cha
|
||||||
if(!IsClient(source_p))
|
if(!IsClient(source_p))
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
|
if (!irccmp(parv[1], "away"))
|
||||||
|
{
|
||||||
|
sendto_one_notice(source_p, ":Please use /AWAY to change your away status");
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
if((parc < 3 || EmptyString(parv[2])) && !EmptyString(parv[1]))
|
if((parc < 3 || EmptyString(parv[2])) && !EmptyString(parv[1]))
|
||||||
{
|
{
|
||||||
if ((val = get_metadata(source_p, parv[1])) != NULL)
|
if ((val = get_metadata(source_p, parv[1])) != NULL)
|
||||||
|
|
Loading…
Reference in a new issue