Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(372)

Side by Side Diff: net/http/http_cache.cc

Issue 185083002: Avoid persisting of QUIC server config information in Stable and Beta (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixed rch's comments from Patch set 1 Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/common/chrome_switches.cc ('k') | net/http/http_network_session.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #include "net/http/http_cache.h" 5 #include "net/http/http_cache.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "base/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 10
(...skipping 272 matching lines...) Expand 10 before | Expand all | Expand 10 after
283 HttpCache* const http_cache_; 283 HttpCache* const http_cache_;
284 }; 284 };
285 285
286 //----------------------------------------------------------------------------- 286 //-----------------------------------------------------------------------------
287 HttpCache::HttpCache(const net::HttpNetworkSession::Params& params, 287 HttpCache::HttpCache(const net::HttpNetworkSession::Params& params,
288 BackendFactory* backend_factory) 288 BackendFactory* backend_factory)
289 : net_log_(params.net_log), 289 : net_log_(params.net_log),
290 backend_factory_(backend_factory), 290 backend_factory_(backend_factory),
291 building_backend_(false), 291 building_backend_(false),
292 mode_(NORMAL), 292 mode_(NORMAL),
293 quic_server_info_factory_(new QuicServerInfoFactoryAdaptor(this)), 293 quic_server_info_factory_(params.enable_quic_persist_server_info ?
294 new QuicServerInfoFactoryAdaptor(this) : NULL),
294 network_layer_(new HttpNetworkLayer(new HttpNetworkSession(params))) { 295 network_layer_(new HttpNetworkLayer(new HttpNetworkSession(params))) {
295 HttpNetworkSession* session = network_layer_->GetSession(); 296 HttpNetworkSession* session = network_layer_->GetSession();
296 session->quic_stream_factory()->set_quic_server_info_factory( 297 session->quic_stream_factory()->set_quic_server_info_factory(
297 quic_server_info_factory_.get()); 298 quic_server_info_factory_.get());
298 } 299 }
299 300
300 301
301 // This call doesn't change the shared |session|'s QuicServerInfoFactory because 302 // This call doesn't change the shared |session|'s QuicServerInfoFactory because
302 // |session| is shared. 303 // |session| is shared.
303 HttpCache::HttpCache(HttpNetworkSession* session, 304 HttpCache::HttpCache(HttpNetworkSession* session,
(...skipping 867 matching lines...) Expand 10 before | Expand all | Expand 10 after
1171 building_backend_ = false; 1172 building_backend_ = false;
1172 DeletePendingOp(pending_op); 1173 DeletePendingOp(pending_op);
1173 } 1174 }
1174 1175
1175 // The cache may be gone when we return from the callback. 1176 // The cache may be gone when we return from the callback.
1176 if (!item->DoCallback(result, disk_cache_.get())) 1177 if (!item->DoCallback(result, disk_cache_.get()))
1177 item->NotifyTransaction(result, NULL); 1178 item->NotifyTransaction(result, NULL);
1178 } 1179 }
1179 1180
1180 } // namespace net 1181 } // namespace net
OLDNEW
« no previous file with comments | « chrome/common/chrome_switches.cc ('k') | net/http/http_network_session.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698