From: Rick Bird Date: Wed, 11 May 2011 22:16:05 +0000 (-0400) Subject: Moved log_all event until AFTER logs X-Git-Url: https://git.theari.com/?a=commitdiff_plain;h=b55a4c91c49380eef543df6a939b49755a0b6f09;p=cobramush.git Moved log_all event until AFTER logs --- diff --git a/src/log.c b/src/log.c index 4ec8e8b..a48e867 100644 --- a/src/log.c +++ b/src/log.c @@ -242,14 +242,15 @@ do_rawlog(int logtype, const char *fmt, ...) f = stderr; break; } - if((chook = (struct core_hook_t *) hashfind("LOG_ALL.AFTER", &chook_htab))) { - for(centry = chook->hooks; centry != NULL ; centry = centry->next) - CHook_Run(centry, "%# %d %s", global_eval_context.cplr, logtype, tbuf1); - } lock_file(f); fprintf(f, "%s %s\n", timebuf, tbuf1); fflush(f); unlock_file(f); + if((chook = (struct core_hook_t *) hashfind("LOG_ALL.AFTER", &chook_htab))) { + for(centry = chook->hooks; centry != NULL ; centry = centry->next) + CHook_Run(centry, "%# %d %s", global_eval_context.cplr, logtype, tbuf1); + } + } /** Log a message, with useful information.