Merge remote-tracking branch 'qatar/master'
[ffmpeg.git] / libavformat / matroskadec.c
index c4a590b..ba53e34 100644 (file)
@@ -1214,8 +1214,10 @@ static int matroska_merge_packets(AVPacket *out, AVPacket *in)
     int ret = av_grow_packet(out, in->size);
     if (ret < 0)
         return ret;
+
     memcpy(out->data + out->size - in->size, in->data, in->size);
-    av_destruct_packet(in);
+
+    av_free_packet(in);
     av_free(in);
     return 0;
 }