[FFmpeg-devel] [PATCH 1/6] avutil/opt: check return value of av_bprint_finalize()

Tim Bradstock tim.bradstock at googlemail.com
Wed Jun 24 17:08:10 EEST 2020


unsubscribe

On Mon, Jun 22, 2020 at 4:32 PM <lance.lmwang at gmail.com> wrote:

> From: Limin Wang <lance.lmwang at gmail.com>
>
> Signed-off-by: Limin Wang <lance.lmwang at gmail.com>
> ---
>  libavutil/opt.c | 5 ++++-
>  1 file changed, 4 insertions(+), 1 deletion(-)
>
> diff --git a/libavutil/opt.c b/libavutil/opt.c
> index 2c3f998..552985e 100644
> --- a/libavutil/opt.c
> +++ b/libavutil/opt.c
> @@ -2120,6 +2120,9 @@ int av_opt_serialize(void *obj, int opt_flags, int
> flags, char **buffer,
>              av_freep(&buf);
>          }
>      }
> -    av_bprint_finalize(&bprint, buffer);
> +    ret = av_bprint_finalize(&bprint, buffer);
> +    if (ret < 0)
> +        return ret;
> +
>      return 0;
>  }
> --
> 1.8.3.1
>
> _______________________________________________
> ffmpeg-devel mailing list
> ffmpeg-devel at ffmpeg.org
> https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
>
> To unsubscribe, visit link above, or email
> ffmpeg-devel-request at ffmpeg.org with subject "unsubscribe".


More information about the ffmpeg-devel mailing list