diff mbox series

[FFmpeg-devel] avcodec/h264_metadata_bsf: Fix invalid av_freep

Message ID 20200704192234.26732-1-andreas.rheinhardt@gmail.com
State Accepted
Commit 04e06beb0ab98a6eb85df32f7809b1143e4bebe7
Headers show
Series [FFmpeg-devel] avcodec/h264_metadata_bsf: Fix invalid av_freep | expand

Checks

Context Check Description
andriy/default pending
andriy/make success Make finished
andriy/make_fate success Make fate finished

Commit Message

Andreas Rheinhardt July 4, 2020, 7:22 p.m. UTC
This bug was introduced in 3c8a2a1180f03ca6b299ebc27eef21ae86635ca0.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
---
Sorry for this.

 libavcodec/h264_metadata_bsf.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

James Almer July 4, 2020, 7:41 p.m. UTC | #1
On 7/4/2020 4:22 PM, Andreas Rheinhardt wrote:
> This bug was introduced in 3c8a2a1180f03ca6b299ebc27eef21ae86635ca0.
> 
> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
> ---
> Sorry for this.
> 
>  libavcodec/h264_metadata_bsf.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/libavcodec/h264_metadata_bsf.c b/libavcodec/h264_metadata_bsf.c
> index 99017653d0..cef054bd65 100644
> --- a/libavcodec/h264_metadata_bsf.c
> +++ b/libavcodec/h264_metadata_bsf.c
> @@ -528,7 +528,7 @@ static int h264_metadata_filter(AVBSFContext *bsf, AVPacket *pkt)
>                  if (err < 0) {
>                      av_log(bsf, AV_LOG_ERROR, "Failed to attach extracted "
>                             "displaymatrix side data to packet.\n");
> -                    av_freep(matrix);
> +                    av_free(matrix);
>                      goto fail;
>                  }
>              }

LGTM
diff mbox series

Patch

diff --git a/libavcodec/h264_metadata_bsf.c b/libavcodec/h264_metadata_bsf.c
index 99017653d0..cef054bd65 100644
--- a/libavcodec/h264_metadata_bsf.c
+++ b/libavcodec/h264_metadata_bsf.c
@@ -528,7 +528,7 @@  static int h264_metadata_filter(AVBSFContext *bsf, AVPacket *pkt)
                 if (err < 0) {
                     av_log(bsf, AV_LOG_ERROR, "Failed to attach extracted "
                            "displaymatrix side data to packet.\n");
-                    av_freep(matrix);
+                    av_free(matrix);
                     goto fail;
                 }
             }