| Index: content/browser/loader/resource_dispatcher_host_impl.cc
|
| diff --git a/content/browser/loader/resource_dispatcher_host_impl.cc b/content/browser/loader/resource_dispatcher_host_impl.cc
|
| index 3849313958054add332c20ecf097b12344f45395..7ef314ef93195eac78aa535c783171f45c5745a0 100644
|
| --- a/content/browser/loader/resource_dispatcher_host_impl.cc
|
| +++ b/content/browser/loader/resource_dispatcher_host_impl.cc
|
| @@ -231,8 +231,9 @@ net::Error CallbackAndReturn(
|
| return net_error;
|
| }
|
|
|
| -int BuildLoadFlagsForRequest(const ResourceHostMsg_Request& request_data,
|
| - int child_id, bool is_sync_load) {
|
| +int BuildLoadFlagsForRequest(
|
| + const ResourceHostMsg_Request& request_data, int child_id,
|
| + bool is_sync_load) {
|
| int load_flags = request_data.load_flags;
|
|
|
| // Although EV status is irrelevant to sub-frames and sub-resources, we have
|
| @@ -701,6 +702,9 @@ void ResourceDispatcherHostImpl::DidReceiveRedirect(ResourceLoader* loader,
|
| void ResourceDispatcherHostImpl::DidReceiveResponse(ResourceLoader* loader) {
|
| ResourceRequestInfoImpl* info = loader->GetRequestInfo();
|
|
|
| + offline_policy_.RequestCompleted(info->GetChildID(), info->GetRouteID(),
|
| + loader->request()->response_info());
|
| +
|
| int render_process_id, render_view_id;
|
| if (!info->GetAssociatedRenderView(&render_process_id, &render_view_id))
|
| return;
|
| @@ -933,6 +937,8 @@ void ResourceDispatcherHostImpl::BeginRequest(
|
| bool is_sync_load = sync_result != NULL;
|
| int load_flags =
|
| BuildLoadFlagsForRequest(request_data, child_id, is_sync_load);
|
| + load_flags |= offline_policy_.GetAdditionalLoadFlags(
|
| + child_id, route_id, load_flags, request_data.resource_type);
|
|
|
| // Construct the request.
|
| scoped_ptr<net::URLRequest> new_request;
|
| @@ -1368,6 +1374,9 @@ void ResourceDispatcherHostImpl::CancelRequestsForRoute(int child_id,
|
| CancelBlockedRequestsForRoute(child_id, *iter);
|
| }
|
| }
|
| +
|
| + // Cleanup the offline state for the route.
|
| + offline_policy_.RouteRemoved(child_id, route_id);
|
| }
|
|
|
| // Cancels the request and removes it from the list.
|
|
|