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

Side by Side Diff: content/browser/net/sqlite_persistent_cookie_store.cc

Issue 294973002: Remove workaround for Cookie Manager Command Line (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove WebView cookie store work around Created 6 years, 2 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
« no previous file with comments | « no previous file | no next file » | 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 "content/browser/net/sqlite_persistent_cookie_store.h" 5 #include "content/browser/net/sqlite_persistent_cookie_store.h"
6 6
7 #include <list> 7 #include <list>
8 #include <map> 8 #include <map>
9 #include <set> 9 #include <set>
10 #include <utility> 10 #include <utility>
(...skipping 1299 matching lines...) Expand 10 before | Expand all | Expand 10 after
1310 cookie_monster = 1310 cookie_monster =
1311 new net::CookieMonster(persistent_store, config.cookie_delegate.get()); 1311 new net::CookieMonster(persistent_store, config.cookie_delegate.get());
1312 if ((config.session_cookie_mode == 1312 if ((config.session_cookie_mode ==
1313 CookieStoreConfig::PERSISTANT_SESSION_COOKIES) || 1313 CookieStoreConfig::PERSISTANT_SESSION_COOKIES) ||
1314 (config.session_cookie_mode == 1314 (config.session_cookie_mode ==
1315 CookieStoreConfig::RESTORED_SESSION_COOKIES)) { 1315 CookieStoreConfig::RESTORED_SESSION_COOKIES)) {
1316 cookie_monster->SetPersistSessionCookies(true); 1316 cookie_monster->SetPersistSessionCookies(true);
1317 } 1317 }
1318 } 1318 }
1319 1319
1320 // In the case of Android WebView, the cookie store may be created 1320 if (CommandLine::ForCurrentProcess()->HasSwitch(
1321 // before the browser process fully initializes -- certainly before
1322 // the main loop ever runs. In this situation, the CommandLine singleton
1323 // will not have been set up. Android tests do not need file cookies
1324 // so always ignore them here.
1325 //
1326 // TODO(ajwong): Remove the InitializedForCurrentProcess() check
1327 // once http://crbug.com/331424 is resolved.
1328 if (base::CommandLine::InitializedForCurrentProcess() &&
1329 base::CommandLine::ForCurrentProcess()->HasSwitch(
1330 switches::kEnableFileCookies)) { 1321 switches::kEnableFileCookies)) {
1331 cookie_monster->SetEnableFileScheme(true); 1322 cookie_monster->SetEnableFileScheme(true);
1332 } 1323 }
1333 1324
1334 return cookie_monster; 1325 return cookie_monster;
1335 } 1326 }
1336 1327
1337 } // namespace content 1328 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698