When the download file is less than the limit speed, it cannot be limited #2371
Comments
Maybe we should just make it /* not enough data yet */
if(!limit)
return -1; What do you think? |
Good idea! |
bagder
added a commit
that referenced
this issue
Mar 10, 2018
... and make sure to avoid integer overflows with really large values. Reported-by: 刘佩东 Fixes #2371
@liupeidong0620 give #2373 a try if you can |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
I did this
Download file size:
Problems with the new version:
Real download time:
real 0m0.145s
I expected the following
Correct performance
Real download time:
real 0m0.936s
The reason for the problem is here
When the download file is less than the limit speed, it cannot be limited
After this code comment, execute the program:
Real download time:
real 0m0.950s
operating system
The text was updated successfully, but these errors were encountered: