From 22869bb94ee6ae30432596d7472220f300d5f438 Mon Sep 17 00:00:00 2001 From: "Carsten Haitzler (Rasterman)" Date: Sat, 12 Dec 2015 23:37:16 +0900 Subject: evas - fix evas module locks to init/del when movile created/destroyed we initted when we load and unload. this led to races with locking/unlocking elsewhere as these expected us to be initted and we were not yet. this fixes that! @fix --- src/lib/evas/file/evas_module.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/lib/evas/file') diff --git a/src/lib/evas/file/evas_module.c b/src/lib/evas/file/evas_module.c index bafc6e7261..cda2dafe69 100644 --- a/src/lib/evas/file/evas_module.c +++ b/src/lib/evas/file/evas_module.c @@ -304,6 +304,7 @@ evas_module_register(const Evas_Module_Api *module, Evas_Module_Type type) em = calloc(1, sizeof (Evas_Module)); if (!em) return EINA_FALSE; + LKI(em->lock); em->definition = module; if (type == EVAS_MODULE_TYPE_ENGINE) @@ -405,6 +406,7 @@ evas_module_unregister(const Evas_Module_Api *module, Evas_Module_Type type) eina_array_data_set(evas_engines, em->id_engine - 1, NULL); eina_hash_del(evas_modules[type], module->name, em); + LKD(em->lock); free(em); return EINA_TRUE; @@ -512,7 +514,6 @@ evas_module_load(Evas_Module *em) if (!em->definition->func.open(em)) return 0; em->loaded = 1; - LKI(em->lock); return 1; } @@ -528,7 +529,6 @@ evas_module_unload(Evas_Module *em) // em->definition->func.close(em); // em->loaded = 0; - LKD(em->lock); } void -- cgit v1.2.1