From a47f3ba8fdee96ee7a3cf5384b393ef05cc51048 Mon Sep 17 00:00:00 2001 From: Chris Michael Date: Tue, 11 Jun 2013 16:42:47 +0100 Subject: [PATCH] Better trapping for already loaded comp module. Signed-off-by: Chris Michael --- src/bin/e_wayland/e_comp.c | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/src/bin/e_wayland/e_comp.c b/src/bin/e_wayland/e_comp.c index e9637f0a0..cf5ff5e0a 100644 --- a/src/bin/e_wayland/e_comp.c +++ b/src/bin/e_wayland/e_comp.c @@ -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; }