[ServiceWorker] Handle bytes_read=0 async result correctly in ServiceWorkerWriteToCacheJob.
The async result of net_request_->Read() in ServiceWorkerWriteToCacheJob::ReadNetData() is passed to ServiceWorkerWriteToCacheJob::OnReadCompleted(). In current code the case when bytes_read is 0 is not handled correctly. So when bytes_read is 0 the script loading will hang. LayoutTest is here: https://codereview.chromium.org/650193003 I hope this patch will reduce the test flakiness :) BUG=419999 TEST=http/tests/serviceworker/chromium/load-flushed-script.html Review URL: https://codereview.chromium.org/640923003 Cr-Commit-Position: refs/heads/master@{#300233}
Showing
Please register or sign in to comment