Skip to content
Snippets Groups Projects
Commit 3de6efd6 authored by Sven M. Hallberg's avatar Sven M. Hallberg
Browse files

revert to shadowing a variable instead of overwriting it

As indicated by the XXX, this line of code was never meant to be
considered as "proper", mainly because it allocates a new parser
that is never freed for every xref section in the file.

The reason that this line was introduced in place of the commented-out
original above it is that the latter does not bounds-check the offset
but h_seek() does. It was a quick and reliable way to make invalid
offsets fail the parse.

Anyway, creating a new HParser *p that incidentally shadows the
previous occurance was meant to signal that this is just a temporary
name that we need real quick (on the next line), not a "proper" variable,
and that it probably wasn't there to stay. So with that sense in mind, I
am putting it back.

Remove -Wshadow from CFLAGS.
parent 83bdf6cd
No related branches found
No related tags found
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment