sensor: capi: change log macro to show logs efficiently 82/204682/1 accepted/tizen_5.0_unified accepted/tizen/5.0/unified/20190502.081316 submit/tizen_5.0/20190429.051715
authorAvichal <avichal.a@samsung.com>
Thu, 25 Apr 2019 11:22:04 +0000 (16:52 +0530)
committerAvichal <avichal.a@samsung.com>
Thu, 25 Apr 2019 11:43:14 +0000 (17:13 +0530)
Change-Id: Ie04d4e4ea5109734bc6efa7977f8a9d820c12311
Signed-off-by: Avichal <avichal.a@samsung.com>
include/sensor_log.h

index 9c9e3ac4c3baa4a6c11b5b3eccfa7d82cf0036dc..e70b435ffc3b3dbd2108510844c1b5e1176907a6 100644 (file)
@@ -24,8 +24,6 @@ extern "C"
 
 #include <dlog.h>
 
-#define _DEBUG 1
-
 #undef LOG_TAG
 #define LOG_TAG        "TIZEN_SYSTEM_SENSOR"
 
@@ -38,17 +36,10 @@ extern "C"
 
 #define _E_MSG(err) SLOGE(_MSG_##err "(0x%08x)", (err))
 
-#ifdef _DEBUG
-       #define _E(fmt, args...) dlog_print(DLOG_ERROR, LOG_TAG, fmt, ##args)
-       #define _W(fmt, args...) dlog_print(DLOG_WARN, LOG_TAG, fmt, ##args)
-       #define _I(fmt, args...) dlog_print(DLOG_INFO, LOG_TAG, fmt, ##args)
-       #define _D(fmt, args...) dlog_print(DLOG_DEBUG, LOG_TAG, fmt, ##args)
-#else
-       #define _E(...)
-       #define _W(...)
-       #define _I(...)
-       #define _D(...)
-#endif
+#define _E(fmt, args...) LOGE(fmt, ##args)
+#define _W(fmt, args...) LOGW(fmt, ##args)
+#define _I(fmt, args...) LOGI(fmt, ##args)
+#define _D(fmt, args...) LOGD(fmt, ##args)
 
 #ifdef __cplusplus
 }