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 <algorithm> | 9 #include <algorithm> |
10 #include <set> | 10 #include <set> |
(...skipping 1289 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1300 // to the job being started. | 1300 // to the job being started. |
1301 storage::BlobProtocolHandler::SetRequestedBlobDataHandle( | 1301 storage::BlobProtocolHandler::SetRequestedBlobDataHandle( |
1302 new_request.get(), | 1302 new_request.get(), |
1303 filter_->blob_storage_context()->context()->GetBlobDataFromPublicURL( | 1303 filter_->blob_storage_context()->context()->GetBlobDataFromPublicURL( |
1304 new_request->url())); | 1304 new_request->url())); |
1305 } | 1305 } |
1306 | 1306 |
1307 // Initialize the service worker handler for the request. We don't use | 1307 // Initialize the service worker handler for the request. We don't use |
1308 // ServiceWorker for synchronous loads to avoid renderer deadlocks. | 1308 // ServiceWorker for synchronous loads to avoid renderer deadlocks. |
1309 ServiceWorkerRequestHandler::InitializeHandler( | 1309 ServiceWorkerRequestHandler::InitializeHandler( |
1310 new_request.get(), | 1310 new_request.get(), filter_->service_worker_context(), blob_context, |
1311 filter_->service_worker_context(), | 1311 child_id, request_data.service_worker_provider_id, |
1312 blob_context, | |
1313 child_id, | |
1314 request_data.service_worker_provider_id, | |
1315 request_data.skip_service_worker || is_sync_load, | 1312 request_data.skip_service_worker || is_sync_load, |
1316 request_data.fetch_request_mode, | 1313 request_data.fetch_request_mode, request_data.fetch_credentials_mode, |
1317 request_data.fetch_credentials_mode, | 1314 request_data.fetch_redirect_mode, request_data.resource_type, |
1318 request_data.resource_type, | 1315 request_data.fetch_request_context_type, request_data.fetch_frame_type, |
1319 request_data.fetch_request_context_type, | |
1320 request_data.fetch_frame_type, | |
1321 request_data.request_body); | 1316 request_data.request_body); |
1322 | 1317 |
1323 // Have the appcache associate its extra info with the request. | 1318 // Have the appcache associate its extra info with the request. |
1324 AppCacheInterceptor::SetExtraRequestInfo( | 1319 AppCacheInterceptor::SetExtraRequestInfo( |
1325 new_request.get(), filter_->appcache_service(), child_id, | 1320 new_request.get(), filter_->appcache_service(), child_id, |
1326 request_data.appcache_host_id, request_data.resource_type, | 1321 request_data.appcache_host_id, request_data.resource_type, |
1327 request_data.should_reset_appcache); | 1322 request_data.should_reset_appcache); |
1328 | 1323 |
1329 scoped_ptr<ResourceHandler> handler( | 1324 scoped_ptr<ResourceHandler> handler( |
1330 CreateResourceHandler( | 1325 CreateResourceHandler( |
(...skipping 201 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1532 route_id, | 1527 route_id, |
1533 -1, // frame_tree_node_id | 1528 -1, // frame_tree_node_id |
1534 0, | 1529 0, |
1535 request_id_, | 1530 request_id_, |
1536 MSG_ROUTING_NONE, // render_frame_id | 1531 MSG_ROUTING_NONE, // render_frame_id |
1537 false, // is_main_frame | 1532 false, // is_main_frame |
1538 false, // parent_is_main_frame | 1533 false, // parent_is_main_frame |
1539 -1, // parent_render_frame_id | 1534 -1, // parent_render_frame_id |
1540 RESOURCE_TYPE_SUB_RESOURCE, | 1535 RESOURCE_TYPE_SUB_RESOURCE, |
1541 ui::PAGE_TRANSITION_LINK, | 1536 ui::PAGE_TRANSITION_LINK, |
1542 false, // should_replace_current_entry | 1537 false, // should_replace_current_entry, |
mmenke
2015/08/14 16:12:05
nit: Remove comma
horo
2015/08/14 18:46:12
Done.
| |
1543 download, // is_download | 1538 download, // is_download |
1544 false, // is_stream | 1539 false, // is_stream |
1545 download, // allow_download | 1540 download, // allow_download |
1546 false, // has_user_gesture | 1541 false, // has_user_gesture |
1547 false, // enable_load_timing | 1542 false, // enable_load_timing |
1548 false, // enable_upload_progress | 1543 false, // enable_upload_progress |
1549 false, // do_not_prompt_for_login | 1544 false, // do_not_prompt_for_login |
1550 blink::WebReferrerPolicyDefault, | 1545 blink::WebReferrerPolicyDefault, |
1551 blink::WebPageVisibilityStateVisible, | 1546 blink::WebPageVisibilityStateVisible, |
1552 context, | 1547 context, |
(...skipping 801 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
2354 if ((load_flags & net::LOAD_REPORT_RAW_HEADERS) | 2349 if ((load_flags & net::LOAD_REPORT_RAW_HEADERS) |
2355 && !policy->CanReadRawCookies(child_id)) { | 2350 && !policy->CanReadRawCookies(child_id)) { |
2356 VLOG(1) << "Denied unauthorized request for raw headers"; | 2351 VLOG(1) << "Denied unauthorized request for raw headers"; |
2357 load_flags &= ~net::LOAD_REPORT_RAW_HEADERS; | 2352 load_flags &= ~net::LOAD_REPORT_RAW_HEADERS; |
2358 } | 2353 } |
2359 | 2354 |
2360 return load_flags; | 2355 return load_flags; |
2361 } | 2356 } |
2362 | 2357 |
2363 } // namespace content | 2358 } // namespace content |
OLD | NEW |