Posted 24 June 2015 - 01:07 AM
Using fs.open("file","r") and fs.open("file","rb") are similar
But what are the benefits to using 'rb' mode?
Is there ever a situation when you CAN't do this:
But what are the benefits to using 'rb' mode?
Is there ever a situation when you CAN't do this:
f = fs.open("file","r")
local firstByte = string.byte( f.readLine() )
f.close()
and would therefore need to use 'rb' mode?
f = fs.open("file","rb")
local firstByte = f.read()
f.close()