| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 // See http://dev.chromium.org/developers/design-documents/multi-process-resourc
e-loading | 5 // See http://dev.chromium.org/developers/design-documents/multi-process-resourc
e-loading |
| 6 | 6 |
| 7 #include "content/browser/loader/resource_dispatcher_host_impl.h" | 7 #include "content/browser/loader/resource_dispatcher_host_impl.h" |
| 8 | 8 |
| 9 #include <set> | 9 #include <set> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 972 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 983 // TODO(darin): Do we really need all of these URLRequest setters in the | 983 // TODO(darin): Do we really need all of these URLRequest setters in the |
| 984 // transferred navigation case? | 984 // transferred navigation case? |
| 985 | 985 |
| 986 request->set_load_flags(load_flags); | 986 request->set_load_flags(load_flags); |
| 987 request->SetPriority(request_data.priority); | 987 request->SetPriority(request_data.priority); |
| 988 | 988 |
| 989 // Resolve elements from request_body and prepare upload data. | 989 // Resolve elements from request_body and prepare upload data. |
| 990 if (request_data.request_body.get()) { | 990 if (request_data.request_body.get()) { |
| 991 webkit_blob::BlobStorageContext* blob_context = NULL; | 991 webkit_blob::BlobStorageContext* blob_context = NULL; |
| 992 if (filter_->blob_storage_context()) | 992 if (filter_->blob_storage_context()) |
| 993 blob_context = filter_->blob_storage_context()->context(), | 993 blob_context = filter_->blob_storage_context()->context(); |
| 994 request->set_upload(UploadDataStreamBuilder::Build( | 994 request->set_upload(UploadDataStreamBuilder::Build( |
| 995 request_data.request_body.get(), | 995 request_data.request_body.get(), |
| 996 blob_context, | 996 blob_context, |
| 997 filter_->file_system_context(), | 997 filter_->file_system_context(), |
| 998 BrowserThread::GetMessageLoopProxyForThread(BrowserThread::FILE) | 998 BrowserThread::GetMessageLoopProxyForThread(BrowserThread::FILE) |
| 999 .get())); | 999 .get())); |
| 1000 } | 1000 } |
| 1001 | 1001 |
| 1002 bool allow_download = request_data.allow_download && | 1002 bool allow_download = request_data.allow_download && |
| 1003 ResourceType::IsFrame(request_data.resource_type); | 1003 ResourceType::IsFrame(request_data.resource_type); |
| (...skipping 865 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1869 if ((load_flags & net::LOAD_REPORT_RAW_HEADERS) | 1869 if ((load_flags & net::LOAD_REPORT_RAW_HEADERS) |
| 1870 && !policy->CanReadRawCookies(child_id)) { | 1870 && !policy->CanReadRawCookies(child_id)) { |
| 1871 VLOG(1) << "Denied unauthorized request for raw headers"; | 1871 VLOG(1) << "Denied unauthorized request for raw headers"; |
| 1872 load_flags &= ~net::LOAD_REPORT_RAW_HEADERS; | 1872 load_flags &= ~net::LOAD_REPORT_RAW_HEADERS; |
| 1873 } | 1873 } |
| 1874 | 1874 |
| 1875 return load_flags; | 1875 return load_flags; |
| 1876 } | 1876 } |
| 1877 | 1877 |
| 1878 } // namespace content | 1878 } // namespace content |
| OLD | NEW |