From c2f861ca42fa1a2fb6f7e85abb7bd44f39c6f2c4 Mon Sep 17 00:00:00 2001 From: Hendrik Leppkes Date: Tue, 27 Oct 2015 14:35:30 +0100 Subject: Replace remaining occurances of av_free_packet with av_packet_unref --- libavdevice/decklink_dec.cpp | 2 +- libavdevice/dshow.c | 2 +- libavdevice/openal-dec.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) (limited to 'libavdevice') diff --git a/libavdevice/decklink_dec.cpp b/libavdevice/decklink_dec.cpp index 747f47e582..89f93de453 100644 --- a/libavdevice/decklink_dec.cpp +++ b/libavdevice/decklink_dec.cpp @@ -48,7 +48,7 @@ static void avpacket_queue_flush(AVPacketQueue *q) pthread_mutex_lock(&q->mutex); for (pkt = q->first_pkt; pkt != NULL; pkt = pkt1) { pkt1 = pkt->next; - av_free_packet(&pkt->pkt); + av_packet_unref(&pkt->pkt); av_freep(&pkt); } q->last_pkt = NULL; diff --git a/libavdevice/dshow.c b/libavdevice/dshow.c index 31764a9637..b280bc314d 100644 --- a/libavdevice/dshow.c +++ b/libavdevice/dshow.c @@ -119,7 +119,7 @@ dshow_read_close(AVFormatContext *s) pktl = ctx->pktl; while (pktl) { AVPacketList *next = pktl->next; - av_free_packet(&pktl->pkt); + av_packet_unref(&pktl->pkt); av_free(pktl); pktl = next; } diff --git a/libavdevice/openal-dec.c b/libavdevice/openal-dec.c index cab1eb6915..e4daf53250 100644 --- a/libavdevice/openal-dec.c +++ b/libavdevice/openal-dec.c @@ -204,7 +204,7 @@ static int read_packet(AVFormatContext* ctx, AVPacket *pkt) fail: /* Handle failure */ if (pkt->data) - av_free_packet(pkt); + av_packet_unref(pkt); if (error_msg) av_log(ctx, AV_LOG_ERROR, "Error: %s\n", error_msg); return error; -- cgit v1.2.3