From: Michael Niedermayer <[email protected]>

Its a waste of cpu cycles otherwise

Signed-off-by: Anton Khirnov <[email protected]>
---
 libavformat/avio.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/libavformat/avio.c b/libavformat/avio.c
index ac15407..8eef3dc 100644
--- a/libavformat/avio.c
+++ b/libavformat/avio.c
@@ -284,7 +284,7 @@ static inline int retry_transfer_wrapper(URLContext *h, 
unsigned char *buf, int
         if (ret)
            fast_retries = FFMAX(fast_retries, 2);
         len += ret;
-        if (url_interrupt_cb())
+        if (len < size && url_interrupt_cb())
             return AVERROR_EXIT;
     }
     return len;
-- 
1.7.5.3

_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel

Reply via email to