bind lasy
[lttv.git] / ltt / branches / poly / lttv / module.c
index e6012f768223fd3121383b68df1a18f33a06d423..44ce77d0fef0cdd6d9897121015d496b1de37289 100644 (file)
@@ -78,7 +78,9 @@ module_load(const char *name, int argc, char **argv)
 
   for(i = 0 ; i < modulesPaths->len ; i++) {
     pathname = g_module_build_path(modulesPaths->pdata[i],name);
-    gm = g_module_open(pathname,0);
+    gm = g_module_open(pathname,G_MODULE_BIND_LAZY);
+       g_critical("module : %s", pathname);
+       g_critical("erreur : %s", g_module_error());
     g_free(pathname);    
     
     if(gm != NULL) break;
@@ -88,12 +90,14 @@ module_load(const char *name, int argc, char **argv)
 
   if(gm == NULL) {
     pathname = g_module_build_path(NULL,name);
-    gm = g_module_open(pathname,0);
+    gm = g_module_open(pathname,G_MODULE_BIND_LAZY);
+       g_critical("module : %s", pathname);
     g_free(pathname);
   }
 
   /* Module cannot be found */
-
+  if(gm==NULL)
+       g_critical("module est null");
   if(gm == NULL) return NULL;
 
   /* Check if the module was already opened using the hopefully canonical name
@@ -138,7 +142,6 @@ LttvModule *
 lttv_module_load(const char *name, int argc, char **argv) 
 {
   LttvModule *m = module_load(name, argc, argv);
-
   if(m != NULL) m->load_count++;
   return m;
 }
This page took 0.023555 seconds and 4 git commands to generate.