struct Client *acptr;
char *to;
+ if (MustBeOper && !IsPrivileged(acptr))
+ {
+ send_reply(from, ERR_NOPRIVILEGES);
+ return HUNTED_NOSUCH;
+ }
/* Assume it's me, if no server or an unregistered client */
if (parc <= server || EmptyString((to = parv[server])) || IsUnknown(from))
return (HUNTED_ISME);
short digitgroups = 0;
struct User* user = cli_user(sptr);
char ip_base64[8];
- char featurebuf[512];
user->last = CurrentTime;
parv[0] = cli_name(sptr);
send_reply(sptr, RPL_YOURHOST, cli_name(&me), version);
send_reply(sptr, RPL_CREATED, creation);
send_reply(sptr, RPL_MYINFO, cli_name(&me), version);
- ircd_snprintf(0, featurebuf, sizeof(featurebuf), FEATURES, FEATURESVALUES);
- send_reply(sptr, RPL_ISUPPORT, featurebuf);
+ send_supported(sptr);
m_lusers(sptr, sptr, 1, parv);
update_load();
motd_signon(sptr);
set_snomask(sptr, tmpmask, SNO_SET);
if (cli_snomask(sptr) && snomask_given)
send_reply(sptr, RPL_SNOMASK, cli_snomask(sptr), cli_snomask(sptr));
- }
+ } else
+ set_snomask(sptr, 0, SNO_SET);
}
/*
* Compare new flags with old flags and send string which
return 0;
}
+int
+send_supported(struct Client *cptr)
+{
+ char featurebuf[512];
+
+ ircd_snprintf(0, featurebuf, sizeof(featurebuf), FEATURES1, FEATURESVALUES1);
+ send_reply(cptr, RPL_ISUPPORT, featurebuf);
+ ircd_snprintf(0, featurebuf, sizeof(featurebuf), FEATURES2, FEATURESVALUES2);
+ send_reply(cptr, RPL_ISUPPORT, featurebuf);
+
+ return 0; /* convenience return, if it's ever needed */
+}