disable custom logging when eina backtrace is active

ref 2df0404226
This commit is contained in:
Mike Blumenkrantz 2016-01-08 11:42:02 -05:00
parent 6a8cbb53da
commit 7334c65748
1 changed files with 11 additions and 1 deletions

View File

@ -27,8 +27,18 @@ _e_log_cb(const Eina_Log_Domain *d, Eina_Log_Level level, const char *file, cons
EINTERN int
e_log_init(void)
{
const char *bt_level;
e_log_dom = eina_log_domain_register("e", EINA_COLOR_WHITE);
bt_level = getenv("EINA_LOG_BACKTRACE");
if (bt_level)
{
int level;
level = strtol(bt_level, NULL, 10);
if (level < 1)
eina_log_print_cb_set(_e_log_cb, NULL);
}
return e_log_dom != -1;
}