Re: embedded zeroes and io.lines
[
Date Prev][
Date Next][
Thread Prev][
Thread Next]
[
Date Index]
[
Thread Index]
- Subject: Re: embedded zeroes and io.lines
- From: Edgar Toernig <froese@...>
- Date: 2006年1月27日 19:39:49 +0100
Roberto Ierusalimschy wrote:
>
> > More to the point, is there a way that I can input lines from files
> > with embedded zeroes using io.lines or file:lines?
>
> No. Lua assumes that "lines" are only meaningful in text files.
Anyway, afaics the code in liolib:read_line accesses out of bound
memory for "0円\n":
l = strlen(p);
if (p[l-1] != '\n')
Ciao, ET.