summaryrefslogtreecommitdiff
path: root/legacy/evas/src
diff options
context:
space:
mode:
authorGustavo Sverzut Barbieri <barbieri@gmail.com>2010-06-11 18:35:40 +0000
committerGustavo Sverzut Barbieri <barbieri@gmail.com>2010-06-11 18:35:40 +0000
commit94ee30952b13b734ce4fdf3bdd645b1b4199a195 (patch)
tree31b8097190c24046d40ff72123e7bbcb9ce25200 /legacy/evas/src
parent0cd94dd382e11108910c6aca5467fadfb61cbaff (diff)
Although evas_debug is flagged with "debug" in the name, messages are critical.
The evas_debug functions are just called from MAGIC_DEBUG errors, that are quite critical, so messages should come out by default, and do that loud with a CRITICAL warning. Raster, cedric and others: now that we have Eina as a common dependency between Evas and Ecore, maybe it is worth to unify the debug system on top of Eina logging? It already provides "abort on critical", runtime configurable log levels. I'd say the same about the magic and safety checks themselves (eina_magic and eina_safety). SVN revision: 49643
Diffstat (limited to '')
-rw-r--r--legacy/evas/src/lib/main.c19
1 files changed, 9 insertions, 10 deletions
diff --git a/legacy/evas/src/lib/main.c b/legacy/evas/src/lib/main.c
index a7e9f29811..f2f369bbce 100644
--- a/legacy/evas/src/lib/main.c
+++ b/legacy/evas/src/lib/main.c
@@ -106,7 +106,7 @@ evas_debug_error(void)
106 _evas_debug_init = 1; 106 _evas_debug_init = 1;
107 } 107 }
108 if (_evas_debug_show) 108 if (_evas_debug_show)
109 DBG("*** EVAS ERROR: Evas Magic Check Failed!!!"); 109 CRIT("Evas Magic Check Failed!!!");
110} 110}
111 111
112void 112void
@@ -119,7 +119,7 @@ evas_debug_input_null(void)
119 _evas_debug_init = 1; 119 _evas_debug_init = 1;
120 } 120 }
121 if (_evas_debug_show) 121 if (_evas_debug_show)
122 DBG("Input object pointer is NULL!"); 122 CRIT("Input object pointer is NULL!");
123 if (_evas_debug_abort) abort(); 123 if (_evas_debug_abort) abort();
124} 124}
125 125
@@ -133,7 +133,7 @@ evas_debug_magic_null(void)
133 _evas_debug_init = 1; 133 _evas_debug_init = 1;
134 } 134 }
135 if (_evas_debug_show) 135 if (_evas_debug_show)
136 DBG("Input object is zero'ed out (maybe a freed object or zero-filled RAM)!"); 136 CRIT("Input object is zero'ed out (maybe a freed object or zero-filled RAM)!");
137 if (_evas_debug_abort) abort(); 137 if (_evas_debug_abort) abort();
138} 138}
139 139
@@ -147,11 +147,11 @@ evas_debug_magic_wrong(DATA32 expected, DATA32 supplied)
147 _evas_debug_init = 1; 147 _evas_debug_init = 1;
148 } 148 }
149 if (_evas_debug_show) 149 if (_evas_debug_show)
150 DBG(" Input object is wrong type\n" 150 CRIT("Input object is wrong type\n"
151 " Expected: %08x - %s\n" 151 " Expected: %08x - %s\n"
152 " Supplied: %08x - %s", 152 " Supplied: %08x - %s",
153 expected, evas_debug_magic_string_get(expected), 153 expected, evas_debug_magic_string_get(expected),
154 supplied, evas_debug_magic_string_get(supplied)); 154 supplied, evas_debug_magic_string_get(supplied));
155 if (_evas_debug_abort) abort(); 155 if (_evas_debug_abort) abort();
156} 156}
157 157
@@ -165,8 +165,7 @@ evas_debug_generic(const char *str)
165 _evas_debug_init = 1; 165 _evas_debug_init = 1;
166 } 166 }
167 if (_evas_debug_show) 167 if (_evas_debug_show)
168 DBG("*** EVAS ERROR:\n" 168 CRIT("%s", str);
169 "%s", (char *)str);
170 if (_evas_debug_abort) abort(); 169 if (_evas_debug_abort) abort();
171} 170}
172 171