From daf4898668d9753c753d9cd3f20ed2051dddeb39 Mon Sep 17 00:00:00 2001 From: wm4 Date: Wed, 14 May 2014 21:02:56 +0200 Subject: vf_vapoursynth: avoid unnecessary waiting It could in theory happen that the filter loop will enter a blocking wait, even though it could make progress by emptying the list of already-filtered images. I'm not quite sure if this could actually cause a real issue - probably not. --- video/filter/vf_vapoursynth.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/video/filter/vf_vapoursynth.c b/video/filter/vf_vapoursynth.c index 4885ff26bc..c63e648603 100644 --- a/video/filter/vf_vapoursynth.c +++ b/video/filter/vf_vapoursynth.c @@ -261,7 +261,7 @@ static int filter_ext(struct vf_instance *vf, struct mp_image *mpi) pthread_cond_broadcast(&p->wakeup); } - if (p->requested[0] && p->requested[0] != &dummy_img) { + while (p->requested[0] && p->requested[0] != &dummy_img) { struct mp_image *out = p->requested[0]; if (out->pts != MP_NOPTS_VALUE) { double duration = out->pts; -- cgit v1.2.3