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

Unified Diff: chrome/browser/profiles/profile_impl_io_data.cc

Issue 10407124: Don't force non-session only cookies to be session only cookies, instead delete on shutdown (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 7 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/profiles/profile_impl_io_data.cc
diff --git a/chrome/browser/profiles/profile_impl_io_data.cc b/chrome/browser/profiles/profile_impl_io_data.cc
index 0f4c4731935be743d702a0d0cf3a07be8b155197..087a29d64f60858056b95fa231b9f09e214fade5 100644
--- a/chrome/browser/profiles/profile_impl_io_data.cc
+++ b/chrome/browser/profiles/profile_impl_io_data.cc
@@ -30,6 +30,7 @@
#include "net/ftp/ftp_network_layer.h"
#include "net/http/http_cache.h"
#include "net/url_request/url_request_job_factory.h"
+#include "webkit/quota/special_storage_policy.h"
using content::BrowserThread;
@@ -82,7 +83,8 @@ void ProfileImplIOData::Handle::Init(
chrome_browser_net::Predictor* predictor,
PrefService* local_state,
IOThread* io_thread,
- bool restore_old_session_cookies) {
+ bool restore_old_session_cookies,
+ quota::SpecialStoragePolicy* special_storage_policy) {
DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
DCHECK(!io_data_->lazy_params_.get());
DCHECK(predictor);
@@ -97,6 +99,7 @@ void ProfileImplIOData::Handle::Init(
lazy_params->media_cache_max_size = media_cache_max_size;
lazy_params->extensions_cookie_path = extensions_cookie_path;
lazy_params->restore_old_session_cookies = restore_old_session_cookies;
+ lazy_params->special_storage_policy = special_storage_policy;
io_data_->lazy_params_.reset(lazy_params);
@@ -344,7 +347,8 @@ void ProfileImplIOData::LazyInitializeInternal(
scoped_refptr<SQLitePersistentCookieStore> cookie_db =
new SQLitePersistentCookieStore(
lazy_params_->cookie_path,
- lazy_params_->restore_old_session_cookies);
+ lazy_params_->restore_old_session_cookies,
+ lazy_params_->special_storage_policy);
cookie_db->SetClearLocalStateOnExit(
profile_params->clear_local_state_on_exit);
cookie_store =
@@ -358,7 +362,7 @@ void ProfileImplIOData::LazyInitializeInternal(
new net::CookieMonster(
new SQLitePersistentCookieStore(
lazy_params_->extensions_cookie_path,
- lazy_params_->restore_old_session_cookies), NULL);
+ lazy_params_->restore_old_session_cookies, NULL), NULL);
// Enable cookies for devtools and extension URLs.
const char* schemes[] = {chrome::kChromeDevToolsScheme,
chrome::kExtensionScheme};
@@ -497,7 +501,7 @@ ProfileImplIOData::InitializeAppRequestContext(
DCHECK(!cookie_path.empty());
scoped_refptr<SQLitePersistentCookieStore> cookie_db =
- new SQLitePersistentCookieStore(cookie_path, false);
+ new SQLitePersistentCookieStore(cookie_path, false, NULL);
cookie_db->SetClearLocalStateOnExit(clear_local_state_on_exit_);
// TODO(creis): We should have a cookie delegate for notifying the cookie
// extensions API, but we need to update it to understand isolated apps

Powered by Google App Engine
This is Rietveld 408576698