}}
-static void\r
-stats_events_cb(char *str, void *ptr)\r
-{\r
- sendto_one_numeric(ptr, RPL_STATSDEBUG, "E :%s", str);\r
-}\r
-\r
-static void\r
-stats_events (struct Client *source_p)\r
-{\r
- rb_dump_events(stats_events_cb, source_p);\r
- send_pop_queue(source_p);\r
+static void
+stats_events_cb(char *str, void *ptr)
+{
+ sendto_one_numeric(ptr, RPL_STATSDEBUG, "E :%s", str);
+}
+
+static void
+stats_events (struct Client *source_p)
+{
+ rb_dump_events(stats_events_cb, source_p);
+ send_pop_queue(source_p);
}
/* stats_pending_glines()
(int) rus.ru_nivcsw);
}
-static void\r
-stats_tstats(struct Client *source_p)\r
-{\r
- struct Client *target_p;\r
- struct ServerStatistics sp;\r
- rb_dlink_node *ptr;\r
-\r
- memcpy(&sp, &ServerStats, sizeof(struct ServerStatistics));\r
-\r
- RB_DLINK_FOREACH(ptr, serv_list.head)\r
- {\r
- target_p = ptr->data;\r
-\r
- sp.is_sbs += target_p->localClient->sendB;\r
- sp.is_sbr += target_p->localClient->receiveB;\r
- sp.is_sti += rb_current_time() - target_p->localClient->firsttime;\r
- sp.is_sv++;\r
- }\r
-\r
- RB_DLINK_FOREACH(ptr, lclient_list.head)\r
- {\r
- target_p = ptr->data;\r
-\r
- sp.is_cbs += target_p->localClient->sendB;\r
- sp.is_cbr += target_p->localClient->receiveB;\r
- sp.is_cti += rb_current_time() - target_p->localClient->firsttime;\r
- sp.is_cl++;\r
- }\r
-\r
- sendto_one_numeric(source_p, RPL_STATSDEBUG,\r
- "T :accepts %u refused %u", \r
- sp.is_ac, sp.is_ref);\r
- sendto_one_numeric(source_p, RPL_STATSDEBUG,\r
- "T :rejected %u delaying %lu", \r
- sp.is_rej, delay_exit_length());\r
- sendto_one_numeric(source_p, RPL_STATSDEBUG,\r
- "T :nicks being delayed %lu", get_nd_count());\r
- sendto_one_numeric(source_p, RPL_STATSDEBUG,\r
- "T :unknown commands %u prefixes %u",\r
- sp.is_unco, sp.is_unpf);\r
- sendto_one_numeric(source_p, RPL_STATSDEBUG,\r
- "T :nick collisions %u saves %u unknown closes %u",\r
- sp.is_kill, sp.is_save, sp.is_ni);\r
- sendto_one_numeric(source_p, RPL_STATSDEBUG,\r
- "T :wrong direction %u empty %u", \r
- sp.is_wrdi, sp.is_empt);\r
- sendto_one_numeric(source_p, RPL_STATSDEBUG,\r
- "T :numerics seen %u", \r
- sp.is_num);\r
- sendto_one_numeric(source_p, RPL_STATSDEBUG,\r
- "T :auth successes %u fails %u",\r
- sp.is_asuc, sp.is_abad);\r
- sendto_one_numeric(source_p, RPL_STATSDEBUG, "T :Client Server");\r
- sendto_one_numeric(source_p, RPL_STATSDEBUG,\r
- "T :connected %u %u",\r
- sp.is_cl, sp.is_sv);\r
- sendto_one_numeric(source_p, RPL_STATSDEBUG,\r
- "T :bytes sent %lluK %lluK",\r
- sp.is_cbs / 1024, \r
- sp.is_sbs / 1024);\r
- sendto_one_numeric(source_p, RPL_STATSDEBUG,\r
- "T :bytes recv %lluK %lluK",\r
- sp.is_cbr / 1024, \r
- sp.is_sbr / 1024);\r
- sendto_one_numeric(source_p, RPL_STATSDEBUG,\r
- "T :time connected %lu %lu",\r
- sp.is_cti, sp.is_sti);\r
+static void
+stats_tstats (struct Client *source_p)
+{
+ tstats (source_p);
}
static void
}
}
-static void\r
-rb_dump_fd_callback(int fd, const char *desc, void *data)\r
-{\r
- struct Client *source_p = data;\r
- sendto_one_numeric(source_p, RPL_STATSDEBUG, "F :fd %-3d desc '%s'", fd, desc);\r
-}\r
-\r
-static void\r
-stats_comm(struct Client *source_p)\r
-{\r
- rb_dump_fd(rb_dump_fd_callback, source_p);\r
- send_pop_queue(source_p);\r
+static void
+rb_dump_fd_callback(int fd, const char *desc, void *data)
+{
+ struct Client *source_p = data;
+ sendto_one_numeric(source_p, RPL_STATSDEBUG, "F :fd %-3d desc '%s'", fd, desc);
+}
+
+static void
+stats_comm(struct Client *source_p)
+{
+ rb_dump_fd(rb_dump_fd_callback, source_p);
+ send_pop_queue(source_p);
}
/*