summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--video/decode/vd_lavc.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/video/decode/vd_lavc.c b/video/decode/vd_lavc.c
index 6fdd1b2cfd..5c97526d7c 100644
--- a/video/decode/vd_lavc.c
+++ b/video/decode/vd_lavc.c
@@ -631,15 +631,15 @@ static void decode(struct dec_video *vd, struct demux_packet *packet,
return;
}
- // Skipped frame, or delayed output due to multithreaded decoding.
- if (!got_picture)
- return;
-
if (ctx->hwdec && ctx->hwdec_failed) {
av_frame_unref(ctx->pic);
return;
}
+ // Skipped frame, or delayed output due to multithreaded decoding.
+ if (!got_picture)
+ return;
+
struct mp_image_params params;
update_image_params(vd, ctx->pic, &params);
vd->codec_pts = mp_pts_from_av(ctx->pic->pkt_pts, NULL);