From 50e6776d56a48be9bcd8118bce3843e54f04d04a Mon Sep 17 00:00:00 2001 From: hisham Date: Sat, 25 Apr 2009 23:10:17 +0000 Subject: fix, to handle abstracted split_url now in dir module git-svn-id: http://luarocks.org/svn/luarocks/trunk@15 9ca3f7c1-7366-0410-b1a3-b5c78f85698c --- src/luarocks/fetch.lua | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/luarocks/fetch.lua b/src/luarocks/fetch.lua index 57e641cf..9d65e6e8 100644 --- a/src/luarocks/fetch.lua +++ b/src/luarocks/fetch.lua @@ -59,7 +59,7 @@ function fetch_url_at_temp_dir(url, tmpname, filename) local protocol, pathname = dir.split_url(url) if protocol == "file" then - return pathname, dir.dir_name(pathname) + return pathname, dir.dir_name(fs.absolute_name(pathname)) else local temp_dir = fs.make_temp_dir(tmpname) if not temp_dir then @@ -122,8 +122,7 @@ end -- or nil followed by an error message. function load_local_rockspec(filename) assert(type(filename) == "string") - - local rockspec, err = persist.load_into_table(filename) + local rockspec, err = persist.load_into_table(fs.absolute_name(filename)) if not rockspec then return nil, "Could not load rockspec file "..filename.." ("..err..")" end -- cgit v1.2.3-55-g6feb