summaryrefslogtreecommitdiff
path: root/src/bin
diff options
context:
space:
mode:
authorDaniel Kolesa <d.kolesa@samsung.com>2014-11-05 09:52:01 +0000
committerDaniel Kolesa <d.kolesa@samsung.com>2014-11-05 09:52:01 +0000
commitd23b9342d5446b688db2187871817d9f0338aefa (patch)
tree108720f4f49a29120469f83f317efe2085b50701 /src/bin
parent1ea00af7e9a0a7bb373c71d50c02f29868de9517 (diff)
elua: remove redundant checks
Diffstat (limited to 'src/bin')
-rw-r--r--src/bin/elua/core/util.lua10
1 files changed, 2 insertions, 8 deletions
diff --git a/src/bin/elua/core/util.lua b/src/bin/elua/core/util.lua
index d4175e1e22..b273054177 100644
--- a/src/bin/elua/core/util.lua
+++ b/src/bin/elua/core/util.lua
@@ -79,10 +79,7 @@ local load_lib_win = function(libname, ev)
79 succ, v = pcall(ffi.load, ev .. "\\lib" .. libname .. ".dll") 79 succ, v = pcall(ffi.load, ev .. "\\lib" .. libname .. ".dll")
80 end 80 end
81 end 81 end
82 if not succ then 82 return succ, v
83 return false, v
84 end
85 return true, v
86end 83end
87 84
88local load_lib = function(libname, ev) 85local load_lib = function(libname, ev)
@@ -95,10 +92,7 @@ local load_lib = function(libname, ev)
95 local ext = (ffi.os == "OSX") and ".dylib" or ".so" 92 local ext = (ffi.os == "OSX") and ".dylib" or ".so"
96 succ, v = pcall(ffi.load, ev .. "/lib" .. libname .. ext) 93 succ, v = pcall(ffi.load, ev .. "/lib" .. libname .. ext)
97 end 94 end
98 if not succ then 95 return succ, v
99 return false, v
100 end
101 return true, v
102end 96end
103 97
104-- makes sure we only keep one handle for each lib 98-- makes sure we only keep one handle for each lib