]> gitweb @ CieloNegro.org - youtube-dl.git/commit
[downloader/http] Finish downloading once received data length matches expected
authorSergey M․ <dstftw@gmail.com>
Tue, 5 May 2020 13:01:25 +0000 (20:01 +0700)
committerSergey M․ <dstftw@gmail.com>
Tue, 5 May 2020 14:43:39 +0000 (21:43 +0700)
commitf7b42518dc4c10d6027bfe7f5e7f186d526b1a4b
treee28ff67055c564bb34014a4e93c99b4d32478299
parentce7db64bf1a558759be63e92f34550d7ba0e4052
[downloader/http] Finish downloading once received data length matches expected

Always do this if possible, i.e. if Content-Length or expected length is known, not only in test.
This will save unnecessary last extra loop trying to read 0 bytes.
youtube_dl/downloader/http.py