Skip to content
Snippets Groups Projects
  • Sven M. Hallberg's avatar
    revert to shadowing a variable instead of overwriting it · 3de6efd6
    Sven M. Hallberg authored
    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.
    3de6efd6
    History