Better trapping for already loaded comp module.
authorChris Michael <devilhorns@comcast.net>
Tue, 11 Jun 2013 15:42:47 +0000 (16:42 +0100)
committerChris Michael <devilhorns@comcast.net>
Tue, 11 Jun 2013 15:42:47 +0000 (16:42 +0100)
Signed-off-by: Chris Michael <devilhorns@comcast.net>
src/bin/e_wayland/e_comp.c

index e9637f0a0a07714389a1d19b75e2b31df18a7abc..cf5ff5e0afc41a9a7636892ab8ef954f5ee9d5e3 100644 (file)
@@ -41,13 +41,15 @@ e_comp_init(void)
      modname = "wl_drm";
 
    if (!(mod = e_module_find(modname)))
-     mod = e_module_new(modname);
-
-   if (mod) 
      {
-        if ((e_module_enable(mod)))
-          return 1;
+        if ((mod = e_module_new(modname)))
+          {
+             if (e_module_enable(mod))
+               return 1;
+          }
      }
+   else
+     return 1;
 
    return 0;
 }