avformat/avidec: Check required demuxing buffer sizes in guess_ni_flag()