aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHisham Muhammad <hisham@gobolinux.org>2014-02-14 15:17:49 -0200
committerHisham Muhammad <hisham@gobolinux.org>2014-02-14 15:17:49 -0200
commit5ae1d1fa46138c1bd715f3f29f1f09375631206a (patch)
tree9dafe495481a2f0be5f2d966770654fb2dbf43c0
parent16a34ad95510e6b84b771b9391fd29c467167150 (diff)
downloadluarocks-5ae1d1fa46138c1bd715f3f29f1f09375631206a.tar.gz
luarocks-5ae1d1fa46138c1bd715f3f29f1f09375631206a.tar.bz2
luarocks-5ae1d1fa46138c1bd715f3f29f1f09375631206a.zip
Fix issue when source.dir got misdetected if URL ends with character 'c'!
How many years did this go undetected?
-rw-r--r--src/luarocks/fetch.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/luarocks/fetch.lua b/src/luarocks/fetch.lua
index 4930ea1d..3448473f 100644
--- a/src/luarocks/fetch.lua
+++ b/src/luarocks/fetch.lua
@@ -235,7 +235,7 @@ function load_local_rockspec(filename, quick)
235 local base = url_to_base_dir(filebase) 235 local base = url_to_base_dir(filebase)
236 rockspec.source.dir = rockspec.source.dir 236 rockspec.source.dir = rockspec.source.dir
237 or rockspec.source.module 237 or rockspec.source.module
238 or ((filebase:match(".lua$") or filebase:match(".c$")) and ".") 238 or ((filebase:match("%.lua$") or filebase:match("%.c$")) and ".")
239 or base 239 or base
240 if rockspec.dependencies then 240 if rockspec.dependencies then
241 for i = 1, #rockspec.dependencies do 241 for i = 1, #rockspec.dependencies do