fix ticket: #6490

Signed-off-by: Steven Liu <l...@onvideo.cn>
---
 libavformat/hls.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/libavformat/hls.c b/libavformat/hls.c
index 0995345bbf..7572fe6e06 100644
--- a/libavformat/hls.c
+++ b/libavformat/hls.c
@@ -898,6 +898,10 @@ static int read_from_url(struct playlist *pls, struct 
segment *seg,
     if (ret > 0)
         pls->cur_seg_offset += ret;
 
+    if (ret > 0 && ret < buf_size) {
+        ret = AVERROR_EOF;
+    }
+
     return ret;
 }
 
-- 
2.11.0 (Apple Git-81)



_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel

Reply via email to