avcodec/bsf: check that AVBSFInternal was allocated before dereferencing it