Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/torch/sys.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornagadomi <nagadomi@nurs.or.jp>2016-09-20 09:28:10 +0300
committernagadomi <nagadomi@nurs.or.jp>2016-09-20 09:28:10 +0300
commitf70da680e64f605fdb34112f542a82c4bec7648f (patch)
tree061cd9376344f5a7ddef66e611414e00b4176063
parentd9803f4ac1dc39f24d7abcb9a70183f7fa48fabc (diff)
Fix type error in find_prefix
-rw-r--r--init.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/init.lua b/init.lua
index 6196fe8..75f1722 100644
--- a/init.lua
+++ b/init.lua
@@ -96,7 +96,7 @@ sys.lla = function(d) d = d or ' ' return execute('ls -la '..d) end
local function find_prefix()
if arg then
for i, v in pairs(arg) do
- if i <= 0 then
+ if type(i) == "number" and type(v) == "string" and i <= 0 then
local lua_path = paths.basename(v)
if lua_path == "luajit" or lua_path == "lua" then
local bin_dir = paths.dirname(v)