http2: support > 64bit sized uploads

... by making sure we don't count down the "upload left" counter when the
uploaded size is unknown and then it can be allowed to continue forever.

Fixes #996
This commit is contained in:
Daniel Stenberg 2016-09-06 23:12:12 +02:00
parent af2d679e14
commit 85033bcfcc
1 changed files with 2 additions and 1 deletions

View File

@ -945,7 +945,8 @@ static ssize_t data_source_read_callback(nghttp2_session *session,
memcpy(buf, stream->upload_mem, nread);
stream->upload_mem += nread;
stream->upload_len -= nread;
stream->upload_left -= nread;
if(data_s->state.infilesize != -1)
stream->upload_left -= nread;
}
if(stream->upload_left == 0)