On 26/11/19 14:31, Michael Niedermayer wrote:
On Thu, Nov 21, 2019 at 06:27:10PM -0300, ggarr...@gmail.com wrote:
From: Gonzalo Garramuño <ggarr...@gmail.com>
This patch is based on a patch by bsenftner at earthlink.net.
---
libavformat/utils.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/libavformat/utils.c b/libavformat/utils.c
index 8196442dd1..c3c2c77c0c 100644
--- a/libavformat/utils.c
+++ b/libavformat/utils.c
@@ -1838,6 +1838,11 @@ int av_read_frame(AVFormatContext *s, AVPacket *pkt)
}
}
+ if (ff_check_interrupt(&s->interrupt_callback)) {
+ av_log(s, AV_LOG_DEBUG, "interrupted\n");
+ return AVERROR_EXIT;
+ }
+
I think this can be moved into the if() above, which might
reduce the number of calls.
thx
[...]
It would probably reduce only one call, as pktl (the if above) is a list
that will get filled probably as soon as there is a packet. Or maybe I
am reading the code wrong? Also, if it does not get filled, we probably
want to exit anyway, too.
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".