0
0
Fork 0
mirror of https://github.com/matrix-construct/construct synced 2024-12-01 19:22:53 +01:00

from ircd-ratbox r25799 by androsyn: give a bit more info when libratbox calls logging callbacks

This commit is contained in:
Valery V Yatsko 2008-08-06 23:12:02 +04:00
parent fc8942feef
commit 6643434b59

View file

@ -447,12 +447,13 @@ setup_corefile(void)
static void
ircd_log_cb(const char *str)
{
ilog(L_MAIN, "%s", str);
ilog(L_MAIN, "libratbox reports: %s", str);
}
static void
ircd_restart_cb(const char *str)
{
ilog(L_MAIN, "libratbox has called the restart callback: %s", str);
restart(str);
}
@ -469,9 +470,11 @@ ircd_die_cb(const char *str)
if(str != NULL)
{
/* Try to get the message out to currently logged in operators. */
sendto_realops_snomask(SNO_GENERAL, L_NETWIDE, "Server panic! %s", str);
inotice("server panic: %s", str);
sendto_realops_snomask(SNO_GENERAL, L_NETWIDE, "libratbox has called the die callback..aborting: %s", str);
inotice("libratbox has called the die callback..aborting: %s", str);
}
else
ilog(L_MAIN, "libratbox has called the die callback..aborting");
unlink(pidFileName);
exit(EXIT_FAILURE);