forked from enlightenment/efl
Evas: Fix crash in GL engine(s) during preload cancel
In my config, running terminology with the GL engine and under cserve2, some image could not be loaded. The tex argument in evas_gl_preload_target_[un]register was NULL, leading to an immediate crash.
This commit is contained in:
parent
13caf63420
commit
ce166ec223
|
@ -408,6 +408,8 @@ _evas_gl_preload_target_die(void *data, Eo *obj,
|
|||
void
|
||||
evas_gl_preload_target_register(Evas_GL_Texture *tex, Eo *target)
|
||||
{
|
||||
EINA_SAFETY_ON_NULL_RETURN(tex);
|
||||
|
||||
eo_do(target,
|
||||
eo_event_callback_add(EO_EV_DEL, _evas_gl_preload_target_die, tex));
|
||||
tex->targets = eina_list_append(tex->targets, target);
|
||||
|
@ -420,6 +422,8 @@ evas_gl_preload_target_unregister(Evas_GL_Texture *tex, Eo *target)
|
|||
Eina_List *l;
|
||||
const Eo *o;
|
||||
|
||||
EINA_SAFETY_ON_NULL_RETURN(tex);
|
||||
|
||||
eo_do(target,
|
||||
eo_event_callback_del(EO_EV_DEL, _evas_gl_preload_target_die, tex));
|
||||
|
||||
|
|
Loading…
Reference in New Issue