summaryrefslogtreecommitdiffhomepage
path: root/libs
diff options
context:
space:
mode:
authorSteven Barth <steven@midlink.org>2009-07-24 17:34:40 +0000
committerSteven Barth <steven@midlink.org>2009-07-24 17:34:40 +0000
commit4d75b511579ab4d833783318451a79327ce756ce (patch)
treed59c8ba3c2063b518b9ee4fe9df4ea623e9c9d3e /libs
parent2164bdf6518261391097be96b2d873c078977434 (diff)
FIx lsat commit
Diffstat (limited to 'libs')
-rw-r--r--libs/core/luasrc/fs.lua6
1 files changed, 3 insertions, 3 deletions
diff --git a/libs/core/luasrc/fs.lua b/libs/core/luasrc/fs.lua
index e2e3abae2..a81ff675d 100644
--- a/libs/core/luasrc/fs.lua
+++ b/libs/core/luasrc/fs.lua
@@ -192,13 +192,13 @@ local stat_tr = {
-- @return Table containing file or directory properties or nil on error
-- @return String containing the error description on error
-- @return Number containing the os specific errno on error
-function stat(...)
- local data, code, msg = fs.stat(...)
+function stat(path, key)
+ local data, code, msg = fs.stat(path)
if data then
data.mode = data.modestr
data.type = stat_tr[data.type] or "?"
end
- return data, code, msg
+ return key and data and data[key] or data, code, msg
end
--- Set permissions on given file or directory.