• Andreas Rheinhardt's avatar
    avformat/hnm: Only keep and parse what is needed later · d2037837
    Andreas Rheinhardt authored
    The hnm demuxer's context struct contained lots of fields that are
    write-only variables or that are not used outside of parsing the header
    and that can therefore be replaced by local variables of hnm_read_header().
    This commit removes all of these from the context; the second type has
    been replaced by local variables.
    
    An AVPacket (that was initialized when reading the header and for which
    dead code to unreference it existed in hnm_read_close()) is among the
    removed things. Removing it allowed to remove hnm_read_close()
    altogether and also removes another instance of usage of sizeof(AVPacket).
    Reviewed-by: 's avatarPaul B Mahol <onemda@gmail.com>
    Signed-off-by: 's avatarAndreas Rheinhardt <andreas.rheinhardt@gmail.com>
    d2037837
hnm.c 4.71 KB