Add support for setting the syslog facility from the config file
This enables setting the syslog facility at build time.
This commit is contained in:
parent
c76e5d7f9b
commit
3e1996216e
2 changed files with 8 additions and 1 deletions
|
@ -78,9 +78,13 @@ void wpa_debug_print_timestamp(void)
|
|||
|
||||
|
||||
#ifdef CONFIG_DEBUG_SYSLOG
|
||||
#ifndef LOG_HOSTAPD
|
||||
#define LOG_HOSTAPD LOG_DAEMON
|
||||
#endif /* LOG_HOSTAPD */
|
||||
|
||||
void wpa_debug_open_syslog(void)
|
||||
{
|
||||
openlog("wpa_supplicant", LOG_PID | LOG_NDELAY, LOG_DAEMON);
|
||||
openlog("wpa_supplicant", LOG_PID | LOG_NDELAY, LOG_HOSTAPD);
|
||||
wpa_debug_syslog++;
|
||||
}
|
||||
|
||||
|
|
|
@ -1225,6 +1225,9 @@ endif
|
|||
|
||||
ifdef CONFIG_DEBUG_SYSLOG
|
||||
CFLAGS += -DCONFIG_DEBUG_SYSLOG
|
||||
ifdef CONFIG_DEBUG_SYSLOG_FACILITY
|
||||
CFLAGS += -DLOG_HOSTAPD="$(CONFIG_DEBUG_SYSLOG_FACILITY)"
|
||||
endif
|
||||
endif
|
||||
|
||||
ifdef CONFIG_DEBUG_FILE
|
||||
|
|
Loading…
Reference in a new issue