[vlc-commits] codec: dav1d: fix potential leak

Francois Cartegnie git at videolan.org
Thu Feb 13 22:41:40 CET 2020


vlc | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Thu Feb 13 17:23:40 2020 +0100| [7e76a2580b5c3331a5653771c71e678fe39a190c] | committer: Francois Cartegnie

codec: dav1d: fix potential leak

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=7e76a2580b5c3331a5653771c71e678fe39a190c
---

 modules/codec/dav1d.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/modules/codec/dav1d.c b/modules/codec/dav1d.c
index ce1a94dbc0..b123a64db2 100644
--- a/modules/codec/dav1d.c
+++ b/modules/codec/dav1d.c
@@ -282,6 +282,8 @@ static int Decode(decoder_t *dec, block_t *block)
         }
     } while (res == 0 || (p_data && p_data->sz != 0));
 
+    if(p_data && p_data->sz > 0)
+        dav1d_data_unref(p_data);
 
     return i_ret;
 }



More information about the vlc-commits mailing list