aboutsummaryrefslogtreecommitdiff
path: root/tar.lua.patch
diff options
context:
space:
mode:
Diffstat (limited to 'tar.lua.patch')
-rw-r--r--tar.lua.patch18
1 files changed, 18 insertions, 0 deletions
diff --git a/tar.lua.patch b/tar.lua.patch
new file mode 100644
index 0000000..a94ee3c
--- /dev/null
+++ b/tar.lua.patch
@@ -0,0 +1,18 @@
1diff --git a/src/luarocks/tools/tar.lua b/src/luarocks/tools/tar.lua
2index 6db1334a..49139615 100644
3--- a/src/luarocks/tools/tar.lua
4+++ b/src/luarocks/tools/tar.lua
5@@ -51,11 +51,11 @@ local function octal_to_number(octal)
6 local number = 0
7 octal = octal:gsub("%s", "")
8 for i = #octal, 1, -1 do
9- local digit = math.tointeger(octal:sub(i, i))
10+ local digit = tonumber(octal:sub(i, i))
11 if not digit then
12 break
13 end
14- number = number + (digit * math.tointeger(8 ^ exp))
15+ number = number + (digit * (8 ^ exp))
16 exp = exp + 1
17 end
18 return number