hermet pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=88e7606b3926ea525233f7298a90fa01cf8c54a4
commit 88e7606b3926ea525233f7298a90fa01cf8c54a4 Author: Jonghee Choi <[email protected]> Date: Thu Dec 8 13:28:39 2016 +0900 access: do not count initted if elm_modapi_init() is fail Summary: When _access_init was called, initted will be increased always even though failed to initialize. This patch will fix this problem. Signed-off-by: Jonghee Choi <[email protected]> Signed-off-by: Minkyu Kang <[email protected]> Reviewers: cedric, Hermet Reviewed By: Hermet Subscribers: joi.choi, jpeg Differential Revision: https://phab.enlightenment.org/D4466 --- src/lib/elementary/elm_access.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/lib/elementary/elm_access.c b/src/lib/elementary/elm_access.c index 27beaa5..20117b9 100644 --- a/src/lib/elementary/elm_access.c +++ b/src/lib/elementary/elm_access.c @@ -161,12 +161,14 @@ static void _access_init(void) { Elm_Module *m; - initted++; - if (initted > 1) return; + + if (initted > 0) return; if (!(m = _elm_module_find_as("access/api"))) return; + if (m->init_func(m) < 0) return; + initted++; + m->api = malloc(sizeof(Mod_Api)); if (!m->api) return; - m->init_func(m); ((Mod_Api *)(m->api) )->out_read = // called to read out some text _elm_module_symbol_get(m, "out_read"); ((Mod_Api *)(m->api) )->out_read_done = // called to set a done marker so when it is reached the done callback is called --
