authd_cmd_handler authd_cmd_handlers[256] = {
['C'] = handle_new_connection,
['D'] = resolve_dns,
- ['H'] = handle_reload,
+ ['R'] = handle_reload,
['S'] = handle_stat,
};
authd_stat_handler handler;
if(parc < 3)
- /* XXX Should log this somehow */
+ {
+ warn_opers(L_CRIT, "BUG: handle_stat received too few parameters (at least 3 expected, got %d)", parc);
return;
+ }
if (!(handler = authd_stat_handlers[(unsigned char)parv[2][0]]))
return;
authd_reload_handler handler;
if(parc < 2)
- /* XXX Should log this somehow */
+ {
+ /* Reload all handlers */
+ for(size_t i = 0; i < 256; handler = authd_reload_handlers[i++])
+ handler(parv[1][0]);
+
return;
+ }
if (!(handler = authd_reload_handlers[(unsigned char)parv[1][0]]))
return;