evas: fix a NULL dereference issue
authorMinwoo, Lee <minwoo47.lee@samsung.com>
Wed, 6 Jan 2016 19:24:16 +0000 (11:24 -0800)
committerCedric BAIL <cedric@osg.samsung.com>
Wed, 6 Jan 2016 21:36:40 +0000 (13:36 -0800)
commit3f5066278ea25e21b80c0f7cf2e5666ad21f3702
tree630f3321f6c3dc0c7525761f3374d6537b365e7f
parentc27fd0fff55dbd29f760f350440cca0ff2bc2e5f
evas: fix a NULL dereference issue

Summary:
If evas engine init failed, it can make crash.
For example
If opengl init failed, then ee->prop.window is 0
ecore_evas_gl_x11_options_new_internal
{
   if (!ee->prop.window)
     {
        ERR("evas_engine_info_set() init engine '%s' failed.", ee->driver);
        ecore_evas_free(ee);
        return NULL;
     }
}

ecore_evas_free calls evas_fonts_zero_pressure
and this time evas->engine.func is NULL so it makes crash.

Reviewers: cedric

Subscribers: cedric, jpeg

Differential Revision: https://phab.enlightenment.org/D3542

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
src/lib/evas/canvas/evas_font_dir.c