On 2016-04-19 19:40:45 +0200, Anton Khirnov wrote:
> Just pass through the bitstream as is. This is the same as what is done
> for HEVC already.
> ---
>  libavcodec/h264_mp4toannexb_bsf.c | 7 ++++++-
>  1 file changed, 6 insertions(+), 1 deletion(-)
> 
> diff --git a/libavcodec/h264_mp4toannexb_bsf.c 
> b/libavcodec/h264_mp4toannexb_bsf.c
> index c1e2a28..0446790 100644
> --- a/libavcodec/h264_mp4toannexb_bsf.c
> +++ b/libavcodec/h264_mp4toannexb_bsf.c
> @@ -134,7 +134,12 @@ static int h264_mp4toannexb_init(AVBSFContext *ctx)
>      int ret;
>  
>      /* retrieve sps and pps NAL units from extradata */
> -    if (ctx->par_in->extradata_size >= 6) {
> +    if (ctx->par_in->extradata_size < 6      ||

extradata with less than 6 bytes certainly doesn't look like annex B

Janne
_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel

Reply via email to