Remove unnecessary calls to av_packet_unref()
av_packet_free() already calls av_packet_unref().
This commit is contained in:
parent
5caeab5f6d
commit
e9096e3e34
2 changed files with 0 additions and 3 deletions
|
@ -51,7 +51,6 @@ record_packet_new(const AVPacket *packet) {
|
|||
|
||||
static void
|
||||
record_packet_delete(struct record_packet *rec) {
|
||||
av_packet_unref(rec->packet);
|
||||
av_packet_free(&rec->packet);
|
||||
free(rec);
|
||||
}
|
||||
|
|
|
@ -151,7 +151,6 @@ stream_push_packet(struct stream *stream, AVPacket *packet) {
|
|||
|
||||
if (stream->pending) {
|
||||
// the pending packet must be discarded (consumed or error)
|
||||
av_packet_unref(stream->pending);
|
||||
av_packet_free(&stream->pending);
|
||||
}
|
||||
|
||||
|
@ -244,7 +243,6 @@ run_stream(void *data) {
|
|||
LOGD("End of frames");
|
||||
|
||||
if (stream->pending) {
|
||||
av_packet_unref(stream->pending);
|
||||
av_packet_free(&stream->pending);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue