diff options
author | michelle legrand <michelle.legrand@openwide.fr> | 2015-01-14 12:02:21 +0100 |
---|---|---|
committer | Cedric BAIL <cedric@osg.samsung.com> | 2015-02-11 17:03:37 +0100 |
commit | 957962476599d99ce2d47257388afd36b342a235 (patch) | |
tree | 6d705a239327e5b4e4eb6e8f1d83c5329e1bf9e7 /src | |
parent | f71a78edcb2fbb2a6156abce3ab8f523eed09c66 (diff) |
eina: fix Eina_Log to only try to free non deleted log.
@fix
Diffstat (limited to 'src')
-rw-r--r-- | src/lib/eina/eina_log.c | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/src/lib/eina/eina_log.c b/src/lib/eina/eina_log.c index 9146ba2745..c3174ff3a5 100644 --- a/src/lib/eina/eina_log.c +++ b/src/lib/eina/eina_log.c | |||
@@ -1202,7 +1202,8 @@ eina_log_print_unlocked(int domain, | |||
1202 | EINA_UNLIKELY(domain < 0)) | 1202 | EINA_UNLIKELY(domain < 0)) |
1203 | { | 1203 | { |
1204 | if (file && fnc && fmt) | 1204 | if (file && fnc && fmt) |
1205 | fprintf( | 1205 | { |
1206 | fprintf( | ||
1206 | stderr, | 1207 | stderr, |
1207 | "CRI: %s:%d %s() eina_log_print() unknown domain %d, original message format '%s'\n", | 1208 | "CRI: %s:%d %s() eina_log_print() unknown domain %d, original message format '%s'\n", |
1208 | file, | 1209 | file, |
@@ -1210,12 +1211,15 @@ eina_log_print_unlocked(int domain, | |||
1210 | fnc, | 1211 | fnc, |
1211 | domain, | 1212 | domain, |
1212 | fmt); | 1213 | fmt); |
1214 | } | ||
1213 | else | 1215 | else |
1214 | fprintf( | 1216 | { |
1217 | fprintf( | ||
1215 | stderr, | 1218 | stderr, |
1216 | "CRI: eina_log_print() unknown domain %d, original message format '%s'\n", | 1219 | "CRI: eina_log_print() unknown domain %d, original message format '%s'\n", |
1217 | domain, | 1220 | domain, |
1218 | fmt ? fmt : ""); | 1221 | fmt ? fmt : ""); |
1222 | } | ||
1219 | 1223 | ||
1220 | if (_abort_on_critical) | 1224 | if (_abort_on_critical) |
1221 | abort(); | 1225 | abort(); |
@@ -1580,10 +1584,12 @@ eina_log_color_disable_set(Eina_Bool disabled) | |||
1580 | 1584 | ||
1581 | for (i = 0; i < _log_domains_count; i++) | 1585 | for (i = 0; i < _log_domains_count; i++) |
1582 | { | 1586 | { |
1587 | if (_log_domains[i].deleted) | ||
1588 | continue; | ||
1589 | |||
1583 | domain = &_log_domains[i]; | 1590 | domain = &_log_domains[i]; |
1584 | 1591 | ||
1585 | if (domain->domain_str) | 1592 | free((char *)domain->domain_str); |
1586 | free((char *)domain->domain_str); | ||
1587 | 1593 | ||
1588 | if ((domain->color) && (!_disable_color)) | 1594 | if ((domain->color) && (!_disable_color)) |
1589 | domain->domain_str = eina_log_domain_str_get(domain->name, domain->color); | 1595 | domain->domain_str = eina_log_domain_str_get(domain->name, domain->color); |