]> git.sesse.net Git - ffmpeg/blobdiff - libavformat/thp.c
avpacket: Replace av_free_packet with av_packet_unref
[ffmpeg] / libavformat / thp.c
index e8ca04f939e68f194f99af77f53dc4be65714692..18d4afea24d333acab5f2b61b7b840d43aa05714 100644 (file)
@@ -168,7 +168,7 @@ static int thp_read_packet(AVFormatContext *s,
 
         ret = av_get_packet(pb, pkt, size);
         if (ret != size) {
-            av_free_packet(pkt);
+            av_packet_unref(pkt);
             return AVERROR(EIO);
         }
 
@@ -176,7 +176,7 @@ static int thp_read_packet(AVFormatContext *s,
     } else {
         ret = av_get_packet(pb, pkt, thp->audiosize);
         if (ret != thp->audiosize) {
-            av_free_packet(pkt);
+            av_packet_unref(pkt);
             return AVERROR(EIO);
         }