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

Side by Side Diff: chrome/browser/profiles/profile_impl_io_data.cc

Issue 10855022: Remove the effects of --disable-restore-session-state. (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Test update. Created 8 years, 4 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/browser/profiles/profile_impl.cc ('k') | chrome/browser/sessions/base_session_service.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 "chrome/browser/profiles/profile_impl_io_data.h" 5 #include "chrome/browser/profiles/profile_impl_io_data.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/file_util.h" 9 #include "base/file_util.h"
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 339 matching lines...) Expand 10 before | Expand all | Expand 10 after
350 DCHECK(!lazy_params_->cookie_path.empty()); 350 DCHECK(!lazy_params_->cookie_path.empty());
351 351
352 scoped_refptr<SQLitePersistentCookieStore> cookie_db = 352 scoped_refptr<SQLitePersistentCookieStore> cookie_db =
353 new SQLitePersistentCookieStore( 353 new SQLitePersistentCookieStore(
354 lazy_params_->cookie_path, 354 lazy_params_->cookie_path,
355 lazy_params_->restore_old_session_cookies, 355 lazy_params_->restore_old_session_cookies,
356 new ClearOnExitPolicy(lazy_params_->special_storage_policy)); 356 new ClearOnExitPolicy(lazy_params_->special_storage_policy));
357 cookie_store = 357 cookie_store =
358 new net::CookieMonster(cookie_db.get(), 358 new net::CookieMonster(cookie_db.get(),
359 profile_params->cookie_monster_delegate); 359 profile_params->cookie_monster_delegate);
360 if (!command_line.HasSwitch(switches::kDisableRestoreSessionState)) 360 cookie_store->GetCookieMonster()->SetPersistSessionCookies(true);
361 cookie_store->GetCookieMonster()->SetPersistSessionCookies(true);
362 } 361 }
363 362
364 net::CookieMonster* extensions_cookie_store = 363 net::CookieMonster* extensions_cookie_store =
365 new net::CookieMonster( 364 new net::CookieMonster(
366 new SQLitePersistentCookieStore( 365 new SQLitePersistentCookieStore(
367 lazy_params_->extensions_cookie_path, 366 lazy_params_->extensions_cookie_path,
368 lazy_params_->restore_old_session_cookies, NULL), NULL); 367 lazy_params_->restore_old_session_cookies, NULL), NULL);
369 // Enable cookies for devtools and extension URLs. 368 // Enable cookies for devtools and extension URLs.
370 const char* schemes[] = {chrome::kChromeDevToolsScheme, 369 const char* schemes[] = {chrome::kChromeDevToolsScheme,
371 chrome::kExtensionScheme}; 370 chrome::kExtensionScheme};
(...skipping 211 matching lines...) Expand 10 before | Expand all | Expand 10 after
583 void ProfileImplIOData::ClearNetworkingHistorySinceOnIOThread( 582 void ProfileImplIOData::ClearNetworkingHistorySinceOnIOThread(
584 base::Time time) { 583 base::Time time) {
585 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); 584 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
586 LazyInitialize(); 585 LazyInitialize();
587 586
588 DCHECK(transport_security_state()); 587 DCHECK(transport_security_state());
589 transport_security_state()->DeleteSince(time); 588 transport_security_state()->DeleteSince(time);
590 DCHECK(http_server_properties_manager()); 589 DCHECK(http_server_properties_manager());
591 http_server_properties_manager()->Clear(); 590 http_server_properties_manager()->Clear();
592 } 591 }
OLDNEW
« no previous file with comments | « chrome/browser/profiles/profile_impl.cc ('k') | chrome/browser/sessions/base_session_service.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698