[MPlayer-cvslog] r37822 - trunk/libmpcodecs/ve_lavc.c

reimar subversion at mplayerhq.hu
Wed Mar 2 22:33:29 CET 2016


Author: reimar
Date: Wed Mar  2 22:33:29 2016
New Revision: 37822

Log:
ve_lavc: unref AVPacket to avoid memleak.

Modified:
   trunk/libmpcodecs/ve_lavc.c

Modified: trunk/libmpcodecs/ve_lavc.c
==============================================================================
--- trunk/libmpcodecs/ve_lavc.c	Wed Mar  2 22:33:28 2016	(r37821)
+++ trunk/libmpcodecs/ve_lavc.c	Wed Mar  2 22:33:29 2016	(r37822)
@@ -845,7 +845,9 @@ static int encode_frame(struct vf_instan
             pict_type_char[lavc_venc_context->coded_frame->pict_type]
             );
     }
-    return pkt.size;
+    res = pkt.size;
+    av_packet_unref(&pkt);
+    return res;
 }
 
 static void uninit(struct vf_instance *vf){


More information about the MPlayer-cvslog mailing list