aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorAndrey Kartashev <andrey.kartashev@afconsult.com>2018-11-02 18:02:13 (GMT)
committerJouni Malinen <j@w1.fi>2018-12-26 14:42:25 (GMT)
commite47c5227bdc1696d537588af1f3b654952570835 (patch)
tree0c802d0d14405d5e9686a71c733004d3679ae1af /src
parent302bbad5ac0df0b96b67ac67244dae9ec2c7b6b9 (diff)
downloadhostap-e47c5227bdc1696d537588af1f3b654952570835.zip
hostap-e47c5227bdc1696d537588af1f3b654952570835.tar.gz
hostap-e47c5227bdc1696d537588af1f3b654952570835.tar.bz2
wpa_debug: Support wpa_hexdump_ascii() outputting into syslog
When syslog logging is used output from wpa_hexdump_ascii() was silently discarded. This patch enables wpa_hexdump_ascii() to print data to syslog but without ASCII decoding. Signed-off-by: Andrey Kartashev <andrey.kartashev@afconsult.com>
Diffstat (limited to 'src')
-rw-r--r--src/utils/wpa_debug.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/utils/wpa_debug.c b/src/utils/wpa_debug.c
index a56462b..c437000 100644
--- a/src/utils/wpa_debug.c
+++ b/src/utils/wpa_debug.c
@@ -422,6 +422,12 @@ static void _wpa_hexdump_ascii(int level, const char *title, const void *buf,
#ifdef CONFIG_ANDROID_LOG
_wpa_hexdump(level, title, buf, len, show);
#else /* CONFIG_ANDROID_LOG */
+#ifdef CONFIG_DEBUG_SYSLOG
+ if (wpa_debug_syslog) {
+ _wpa_hexdump(level, title, buf, len, show);
+ return;
+ }
+#endif /* CONFIG_DEBUG_SYSLOG */
wpa_debug_print_timestamp();
#ifdef CONFIG_DEBUG_FILE
if (out_file) {