Chromium Code Reviews
DescriptionFix an issue that we didn't clean url request properly.
The ByteStreamReader we used in DownloadFile does not support Close()
api, so we need to close the url request on UI thread if
"ByteStreamReader::Close" should be called.
Before we implement parallel download, we null out the callback on
ByteStreamReader during download interruption, and on UI thread, we
cancel the url request. But for parallel download, at some point, we
won't interrupt the download but need to cancel a particular request.
There is another CL that implements a browser test for parallel download and it will test the code here.
https://codereview.chromium.org/2819483002/
BUG=710576, 644352
Review-Url: https://codereview.chromium.org/2811293004
Cr-Commit-Position: refs/heads/master@{#465289}
Committed: https://chromium.googlesource.com/chromium/src/+/b444a98187571cf9ec627ac52fee7e81ffcecb93
Patch Set 1 #Patch Set 2 : Fixed compiling for unit tests. #
Total comments: 6
Patch Set 3 : Work on feedback. #
Total comments: 4
Patch Set 4 : Polish on details. #Patch Set 5 : Clean rebase. #Patch Set 6 : Fix the tests. #Patch Set 7 : Removed a DCHECK for unit test. #
Total comments: 11
Messages
Total messages: 38 (24 generated)
|