summaryrefslogtreecommitdiff
path: root/src/lib/evas/file
diff options
context:
space:
mode:
authorCarsten Haitzler (Rasterman) <raster@rasterman.com>2015-12-12 23:37:16 +0900
committerCarsten Haitzler (Rasterman) <raster@rasterman.com>2015-12-12 23:37:16 +0900
commit22869bb94ee6ae30432596d7472220f300d5f438 (patch)
tree3bd9d31dbecbbbcb613dcd111ae4922137d429bb /src/lib/evas/file
parent0848792204d47b5fb6d84793ff79ec9309e668d3 (diff)
downloadefl-22869bb94ee6ae30432596d7472220f300d5f438.tar.gz
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
Diffstat (limited to 'src/lib/evas/file')
-rw-r--r--src/lib/evas/file/evas_module.c4
1 files changed, 2 insertions, 2 deletions
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