aboutsummaryrefslogtreecommitdiffstats
path: root/sample
diff options
context:
space:
mode:
authorzheng_wenlong <wenlong_zheng@nexty-ele.com>2017-11-09 13:05:19 +0900
committerZheng Wenlong <wenlong_zheng@nexty-ele.com>2017-11-10 00:13:38 +0000
commitd97eb6052b7652a42d502e5887bd7acf3fc6d91b (patch)
treeebd01d960c41d6d9a27da35f6f1924e28afeda6e /sample
parent390902a6b002c6af183c939749fdebfcc4b3e839 (diff)
Set default debug level to error
Default enable HMI_ERROR output. Remove afb-binding.h and add necessary header files. [Patch Set 2] Change LOG_LEVEL_MAX value equal LOG_LEVEL_DEBUG. Change-Id: Ie8c4902f13b600c2b3f5c7d2e924bfa3a22dfc52 Signed-off-by: zheng_wenlong <wenlong_zheng@nexty-ele.com>
Diffstat (limited to 'sample')
-rw-r--r--sample/simple-egl/include/hmi-debug.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/sample/simple-egl/include/hmi-debug.h b/sample/simple-egl/include/hmi-debug.h
index 28aeddf..28705f5 100644
--- a/sample/simple-egl/include/hmi-debug.h
+++ b/sample/simple-egl/include/hmi-debug.h
@@ -19,7 +19,9 @@
#include <time.h>
#include <stdio.h>
+#include <stdarg.h>
#include <string.h>
+#include <stdlib.h>
enum LOG_LEVEL{
LOG_LEVEL_NONE = 0,
@@ -28,7 +30,7 @@ enum LOG_LEVEL{
LOG_LEVEL_NOTICE,
LOG_LEVEL_INFO,
LOG_LEVEL_DEBUG,
- LOG_LEVEL_MAX = LOG_LEVEL_ERROR
+ LOG_LEVEL_MAX = LOG_LEVEL_DEBUG
};
#define __FILENAME__ (strrchr(__FILE__, '/') ? strrchr(__FILE__, '/') + 1 : __FILE__)
@@ -43,7 +45,7 @@ static char ERROR_FLAG[6][20] = {"NONE", "ERROR", "WARNING", "NOTICE", "INFO", "
static void _HMI_LOG(enum LOG_LEVEL level, const char* file, const char* func, const int line, const char* prefix, const char* log, ...)
{
- const int log_level = (getenv("USE_HMI_DEBUG") == NULL)?0:atoi(getenv("USE_HMI_DEBUG"));
+ const int log_level = (getenv("USE_HMI_DEBUG") == NULL)?LOG_LEVEL_ERROR:atoi(getenv("USE_HMI_DEBUG"));
if(log_level < level)
{
return;