forked from izaya/OC-PsychOS2
made io.input open buffers with mode t, for use with readline coming soonTM
This commit is contained in:
parent
87596c8834
commit
1cc220d38e
@ -8,7 +8,7 @@ end
|
|||||||
|
|
||||||
function io.input(fd) -- table -- table -- Sets the default input stream to *fd* if provided, either as a buffer as a path. Returns the default input stream.
|
function io.input(fd) -- table -- table -- Sets the default input stream to *fd* if provided, either as a buffer as a path. Returns the default input stream.
|
||||||
if type(fd) == "string" then
|
if type(fd) == "string" then
|
||||||
fd=io.open(fd,"rb")
|
fd=io.open(fd,"rbt")
|
||||||
end
|
end
|
||||||
if fd then
|
if fd then
|
||||||
os.setenv("STDIN",fd)
|
os.setenv("STDIN",fd)
|
||||||
|
Loading…
Reference in New Issue
Block a user