log: make syslog facility and level configurable, always log filename+lineno

This commit is contained in:
Daniel Eklöf 2020-02-20 19:49:27 +01:00
parent df1a004f97
commit 0794b453dd
No known key found for this signature in database
GPG key ID: 5BBD4992C116573F
3 changed files with 26 additions and 15 deletions

2
main.c
View file

@ -275,7 +275,7 @@ main(int argc, char *const *argv)
}
}
log_init(log_colorize, log_syslog);
log_init(log_colorize, log_syslog, LOG_FACILITY_USER, LOG_CLASS_WARNING);
const struct sigaction sa = {.sa_handler = &signal_handler};
sigaction(SIGINT, &sa, NULL);