1
1
mirror of https://git.shadowkat.net/izaya/OC-PsychOS2.git synced 2024-12-26 04:27:46 -05:00

never mind no reading files line by line in fs.read

This commit is contained in:
XeonSquared 2019-07-21 17:45:22 +10:00
parent 63cb1ceea4
commit 8e3ee7bcb2

View File

@ -29,19 +29,8 @@ for k,v in pairs({"makeDirectory","exists","isDirectory","list","lastModified","
end
local function fread(self,length)
length = length or "*l"
if length == "*a" then
length = math.huge
elseif length == "*l" then
local rstr, lstr = "", ""
while true do
lstr = fs.mounts[self.fs].read(self.fid,1)
if lstr == "\n" or not lstr then
break
end
rstr = rstr .. lstr
end
return rstr
end
if type(length) == "number" then
local rstr, lstr = "", ""