removed some unnecessary stuff
This commit is contained in:
parent
f5262fad08
commit
7e41ce6ee2
@ -23,14 +23,12 @@ end
|
|||||||
|
|
||||||
local function readBuffer(fi)
|
local function readBuffer(fi)
|
||||||
local stream = {}
|
local stream = {}
|
||||||
if fi:read(4) ~= "lz16" and not tO.f then
|
if fi:read(4) ~= "lz16" then
|
||||||
return false, "not an lz16 archive"
|
return false, "not an lz16 archive"
|
||||||
end
|
end
|
||||||
function stream.read()
|
function stream.read()
|
||||||
local len = toint(fi:read(2) or "\0\0")
|
local len = toint(fi:read(2) or "\0\0")
|
||||||
if len < 1 then
|
if len < 1 then
|
||||||
print("nothing")
|
|
||||||
coroutine.yield()
|
|
||||||
return nil
|
return nil
|
||||||
end
|
end
|
||||||
coroutine.yield()
|
coroutine.yield()
|
||||||
@ -58,7 +56,6 @@ end
|
|||||||
|
|
||||||
function lz16.buffer(stream)
|
function lz16.buffer(stream)
|
||||||
if stream.mode.w then
|
if stream.mode.w then
|
||||||
print("write")
|
|
||||||
return writeBuffer(stream)
|
return writeBuffer(stream)
|
||||||
end
|
end
|
||||||
return readBuffer(stream)
|
return readBuffer(stream)
|
||||||
|
Loading…
Reference in New Issue
Block a user