Delete Evas callbacks on win deletion
A crash happens when a movie finishes and the program terminates. An access to the "inf" data is done, although this data has been freed during the win deletion. It crashes only if the mouse is not over the progress bar. @fix
This commit is contained in:
parent
29b515cd0f
commit
409361142d
|
@ -28,6 +28,8 @@ _cb_unfullscreen(void *data EINA_UNUSED, Evas_Object *obj, void *event EINA_UNUS
|
||||||
evas_object_hide(inf->event2);
|
evas_object_hide(inf->event2);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static void
|
||||||
|
_cb_mouse_move(void *data, Evas *evas, Evas_Object *obj, void *event_info);
|
||||||
static void
|
static void
|
||||||
_cb_win_del(void *data EINA_UNUSED, Evas *e EINA_UNUSED, Evas_Object *obj, void *ev EINA_UNUSED)
|
_cb_win_del(void *data EINA_UNUSED, Evas *e EINA_UNUSED, Evas_Object *obj, void *ev EINA_UNUSED)
|
||||||
{
|
{
|
||||||
|
@ -46,6 +48,17 @@ _cb_win_del(void *data EINA_UNUSED, Evas *e EINA_UNUSED, Evas_Object *obj, void
|
||||||
if (vid->uri) efreet_uri_free(vid->uri);
|
if (vid->uri) efreet_uri_free(vid->uri);
|
||||||
free(vid);
|
free(vid);
|
||||||
}
|
}
|
||||||
|
evas_object_event_callback_del_full(inf->event, EVAS_CALLBACK_MOUSE_MOVE,
|
||||||
|
_cb_mouse_move, obj);
|
||||||
|
evas_object_event_callback_del_full(inf->event, EVAS_CALLBACK_MOUSE_IN,
|
||||||
|
_cb_mouse_move, obj);
|
||||||
|
evas_object_event_callback_del_full(inf->event, EVAS_CALLBACK_MOUSE_DOWN,
|
||||||
|
_cb_mouse_move, obj);
|
||||||
|
evas_object_event_callback_del_full(inf->event2, EVAS_CALLBACK_MOUSE_MOVE,
|
||||||
|
_cb_mouse_move, obj);
|
||||||
|
evas_object_event_callback_del_full(inf->event2, EVAS_CALLBACK_MOUSE_OUT,
|
||||||
|
_cb_mouse_move, obj);
|
||||||
|
|
||||||
evas_object_data_del(obj, "inf");
|
evas_object_data_del(obj, "inf");
|
||||||
free(inf);
|
free(inf);
|
||||||
dnd_shutdown();
|
dnd_shutdown();
|
||||||
|
|
Loading…
Reference in New Issue