X-Git-Url: http://git.pk910.de/?a=blobdiff_plain;f=ircd%2Fs_stats.c;h=34eb34a16e23e442784d8a9f4bfb5b1224e1dc79;hb=b44d5859e9dbca964d833742b08dbd3ecde318e1;hp=886abda90b3f392873b0014bd8602bfad46e0611;hpb=592e569802dbc1d90a0095d6f8fed409d6bf8c39;p=ircu2.10.12-pk.git diff --git a/ircd/s_stats.c b/ircd/s_stats.c index 886abda..34eb34a 100644 --- a/ircd/s_stats.c +++ b/ircd/s_stats.c @@ -318,9 +318,24 @@ stats_quarantine(struct Client* to, struct StatDesc* sd, int stat, char* param) if (param && match(param, qline->chname)) /* narrow search */ continue; send_reply(to, RPL_STATSQLINE, qline->chname, qline->reason); - } - } + } +} +static void +stats_mapping(struct Client *to, struct StatDesc* sd, int stat, char* param) +{ + struct s_map *map; + + send_reply(to, RPL_STATSRLINE, "Command", "Name", "Prepend", "Target"); + for (map = GlobalServiceMapList; map; map = map->next) { + struct nick_host *nh; + for (nh = map->services; nh; nh = nh->next) { + send_reply(to, RPL_STATSRLINE, map->command, map->name, + (map->prepend ? map->prepend : "*"), nh->nick); + } + } +} + static void stats_uptime(struct Client* to, struct StatDesc* sd, int stat, char* param) { @@ -453,8 +468,11 @@ struct StatDesc statsinfo[] = { { 'q', (STAT_FLAG_OPERONLY | STAT_FLAG_VARPARAM), FEAT_HIS_STATS_q, stats_quarantine, 0, "Quarantined channels list." }, + { 'R', (STAT_FLAG_OPERFEAT | STAT_FLAG_CASESENS), FEAT_HIS_STATS_R, + stats_mapping, 0, + "Service mappings." }, #ifdef DEBUGMODE - { 'r', STAT_FLAG_OPERFEAT, FEAT_HIS_STATS_r, + { 'r', (STAT_FLAG_OPERFEAT | STAT_FLAG_CASESENS), FEAT_HIS_STATS_r, send_usage, 0, "System resource usage (Debug only)." }, #endif