* commit '598ce4ab4f1893e0661fc038101487e511937877': h264: call av_frame_unref() instead of avcodec_get_frame_defaults(). Conflicts: libavcodec/h264.c
Unified · Split
| @@ -1379,8 +1379,8 @@ int ff_h264_alloc_tables(H264Context *h) · 1378 unmodified lines | |||
| 1379 | if (!h->DPB) | 1379 | if (!h->DPB) |
| 1380 | return AVERROR(ENOMEM); | 1380 | return AVERROR(ENOMEM); |
| 1381 | for (i = 0; i < MAX_PICTURE_COUNT; i++) | 1381 | for (i = 0; i < MAX_PICTURE_COUNT; i++) |
| 1382 | avcodec_get_frame_defaults(&h->DPB[i].f); | 1382 | av_frame_unref(&h->DPB[i].f); |
| 1383 | avcodec_get_frame_defaults(&h->cur_pic.f); | 1383 | av_frame_unref(&h->cur_pic.f); |
| 1384 | } | 1384 | } |
| 1385 | 1385 | ||
| 1386 | return 0; | 1386 | return 0; |
| @@ -1815,7 +1815,7 @@ static int decode_update_thread_context(AVCodecContext *dst, · 428 unmodified lines | |||
| 1815 | h->context_initialized = 0; | 1815 | h->context_initialized = 0; |
| 1816 | 1816 | ||
| 1817 | memset(&h->cur_pic, 0, sizeof(h->cur_pic)); | 1817 | memset(&h->cur_pic, 0, sizeof(h->cur_pic)); |
| 1818 | avcodec_get_frame_defaults(&h->cur_pic.f); | 1818 | av_frame_unref(&h->cur_pic.f); |
| 1819 | h->cur_pic.tf.f = &h->cur_pic.f; | 1819 | h->cur_pic.tf.f = &h->cur_pic.f; |
| 1820 | 1820 | ||
| 1821 | ret = ff_h264_alloc_tables(h); | 1821 | ret = ff_h264_alloc_tables(h); |