[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: -fsanitize=memory
- From: Roberto Ierusalimschy <roberto@...>
- Date: Fri, 22 Nov 2019 10:58:54 -0300
> > MemorySanitizer: use-of-uninitialized-value /home/mpech/lua-5.3.5/src/liolib.c:490:58 in read_line
> Here is the line in question:
> while (i < LUAL_BUFFERSIZE && (c = l_getc(f)) != EOF && c != '\n')
> The tool seems to think that c is uninitialized, which is clearly
> wrong given this line just before the loop:
> int c = '\0';
> What am I missing?
Might it be some problem inside macro 'l_getc' (which can be either
getc or getc_unlocked)?