mirror of https://github.com/omar-polo/gmid.git
fix wrong arguments order for send_log
This commit is contained in:
parent
03747a6c51
commit
ef352ec3b8
6
log.c
6
log.c
|
@ -95,7 +95,7 @@ fatal(const char *fmt, ...)
|
|||
|
||||
va_start(ap, fmt);
|
||||
if ((r = vasprintf(&fmted, fmt, ap)) != -1) {
|
||||
send_log(LOG_CRIT, IMSG_LOG, fmted, r+1);
|
||||
send_log(IMSG_LOG, LOG_CRIT, fmted, r+1);
|
||||
free(fmted);
|
||||
|
||||
/* wait for the logger process to shut down */
|
||||
|
@ -140,7 +140,7 @@ vlog(int priority, struct client *c,
|
|||
if (ec < 0)
|
||||
fatal("asprintf: %s", strerror(errno));
|
||||
|
||||
send_log(priority, IMSG_LOG, s, ec+1);
|
||||
send_log(IMSG_LOG, priority, s, ec+1);
|
||||
|
||||
free(fmted);
|
||||
free(s);
|
||||
|
@ -253,7 +253,7 @@ log_request(struct client *c, char *meta, size_t l)
|
|||
(int)(t-meta), meta);
|
||||
if (ec < 0)
|
||||
err(1, "asprintf");
|
||||
send_log(LOG_NOTICE, IMSG_LOG_REQUEST, fmted, ec+1);
|
||||
send_log(IMSG_LOG_REQUEST, LOG_NOTICE, fmted, ec+1);
|
||||
free(fmted);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue