Check return value of get_chunk_header(). Since enum can be unsigned, the