summaryrefslogtreecommitdiff
path: root/libavformat
diff options
context:
space:
mode:
authorraymondzheng <raymondzheng1412@gmail.com>2017-05-18 14:35:31 +0800
committerMichael Niedermayer <michael@niedermayer.cc>2017-06-09 13:27:44 +0200
commit9f20cc5c84589afe96499fd7259eb821e31217a0 (patch)
tree006bd24c67be39b26db33c88f9f6bb52ddf7e4db /libavformat
parent2336c76b224628f20ed0ef8a683ad602ed1739c3 (diff)
libavformat/http: return EIO when ffurl_read return 0, but s->off < target_end
Approved-by: "Ronald S. Bultje" <rsbultje@gmail.com> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Diffstat (limited to 'libavformat')
-rw-r--r--libavformat/http.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavformat/http.c b/libavformat/http.c
index d06103ab6d..30890bb7aa 100644
--- a/libavformat/http.c
+++ b/libavformat/http.c
@@ -1326,7 +1326,7 @@ static int http_buf_read(URLContext *h, uint8_t *buf, int size)
}
if (len > 0) {
s->off += len;
- if (s->chunksize > 0) {
+ if (s->chunksize > 0 && s->chunksize != UINT64_MAX) {
av_assert0(s->chunksize >= len);
s->chunksize -= len;
}