Re: How to get file size?
[
Date Prev][
Date Next][
Thread Prev][
Thread Next]
[
Date Index]
[
Thread Index]
- Subject: Re: How to get file size?
- From: Jeff Pohlmeyer <yetanothergeek@...>
- Date: 2011年4月19日 04:43:00 -0500
On Tue, Apr 19, 2011 at 4:35 AM, Gilles Ganault wrote:
> Am I missing some module it needs for file operation?
You should check the return value and error message from io.open :
local libs_file, err = io.open("librt.so.0","r")
if (libs_file) then
print(fsize(libs_file))
libs_file:close()
else
print("ERROR:", err)
end
- Jeff