Commit 648b7492 authored by Dmitry Shmidt's avatar Dmitry Shmidt
Browse files

Set ANDROID_LOG_NAME depending on application


Change-Id: I8ef6f87c92b01a089817a4902d33bf5d0c3a5a7a
Signed-off-by: default avatarDmitry Shmidt <dimitrysh@google.com>
parent b98d1c27
......@@ -13,6 +13,9 @@ include $(LOCAL_PATH)/.config
# To ignore possible wrong network configurations
L_CFLAGS = -DWPA_IGNORE_CONFIG_ERRORS
# Set Android log name
L_CFLAGS += -DANDROID_LOG_NAME=\"hostapd\"
ifdef CONFIG_DRIVER_NL80211
L_CFLAGS += -DANDROID_BRCM_P2P_PATCH
endif
......
......@@ -32,6 +32,10 @@ int wpa_debug_timestamp = 0;
#include <android/log.h>
#ifndef ANDROID_LOG_NAME
#define ANDROID_LOG_NAME "wpa_supplicant"
#endif
void android_printf(int level, char *format, ...)
{
if (level >= wpa_debug_level) {
......@@ -45,7 +49,7 @@ void android_printf(int level, char *format, ...)
else
level = ANDROID_LOG_DEBUG;
va_start(ap, format);
__android_log_vprint(level, "wpa_supplicant", format, ap);
__android_log_vprint(level, ANDROID_LOG_NAME, format, ap);
va_end(ap);
}
}
......
......@@ -31,6 +31,9 @@ include $(LOCAL_PATH)/.config
# To ignore possible wrong network configurations
L_CFLAGS = -DWPA_IGNORE_CONFIG_ERRORS
# Set Android log name
L_CFLAGS += -DANDROID_LOG_NAME=\"wpa_supplicant\"
ifdef CONFIG_DRIVER_NL80211
L_CFLAGS += -DANDROID_BRCM_P2P_PATCH
endif
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment