Chromium Code Reviews| Index: content/browser/download/download_job_factory.cc |
| diff --git a/content/browser/download/download_job_factory.cc b/content/browser/download/download_job_factory.cc |
| index f1704709ba5c907fd8c9592b9693cf6cc1b96066..c3d9c1e89919b9e84587f381d08b112412aac584 100644 |
| --- a/content/browser/download/download_job_factory.cc |
| +++ b/content/browser/download/download_job_factory.cc |
| @@ -28,6 +28,7 @@ bool IsParallelizableDownload(const DownloadCreateInfo& create_info) { |
| // 4. Content-Length header. |
| // 5. Content-Length is no less than the minimum slice size configuration. |
| // 6. HTTP/1.1 protocol, not QUIC nor HTTP/1.0. |
| + // 7. HTTP or HTTPS scheme with GET method in the initial request. |
| // Etag and last modified are stored into DownloadCreateInfo in |
| // DownloadRequestCore only if the response header complies to the strong |
| @@ -39,10 +40,12 @@ bool IsParallelizableDownload(const DownloadCreateInfo& create_info) { |
| create_info.total_bytes >= GetMinSliceSizeConfig(); |
| bool satisfy_connection_type = create_info.connection_info == |
| net::HttpResponseInfo::CONNECTION_INFO_HTTP1_1; |
| + bool http_get_method = |
| + create_info.method == "GET" && create_info.url().SchemeIsHTTPOrHTTPS(); |
| bool is_parallelizable = has_strong_validator && create_info.accept_range && |
|
qinmin
2017/05/22 21:24:50
you need to add a new UMA enum for this
xingliu
2017/05/22 22:01:49
Done.
|
| has_content_length && satisfy_min_file_size && |
| - satisfy_connection_type; |
| + satisfy_connection_type && http_get_method; |
| if (!IsParallelDownloadEnabled()) |
| return is_parallelizable; |