---
On top of 14/17. Cannot use the cap since it is on decode_frame.
Vittorio
libavcodec/svq1enc.c | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/libavcodec/svq1enc.c b/libavcodec/svq1enc.c
index 7620332..c93f696 100644
--- a/libavcodec/svq1enc.c
+++ b/libavcodec/svq1enc.c
@@ -621,8 +621,15 @@ static int svq1_encode_frame(AVCodecContext *avctx,
AVPacket *pkt,
s->frame_width / (i ? 4 : 1),
s->frame_height / (i ? 4 : 1),
pict->linesize[i],
- s->current_picture->linesize[i]) < 0)
+ s->current_picture->linesize[i]) < 0) {
+ int j;
+ for (j = 0; j < i; j++) {
+ av_freep(&s->motion_val8[j]);
+ av_freep(&s->motion_val16[j]);
+ }
+ av_freep(&s->scratchbuf);
return -1;
+ }
// avpriv_align_put_bits(&s->pb);
while (put_bits_count(&s->pb) & 31)
--
1.9.5 (Apple Git-50.3)
_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel