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

Side by Side Diff: chrome/browser/safe_browsing/safe_browsing_service.cc

Issue 23964011: Reuse webview classic cookies file (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: minor fix Created 7 years, 3 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
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/safe_browsing/safe_browsing_service.h" 5 #include "chrome/browser/safe_browsing/safe_browsing_service.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/bind_helpers.h" 8 #include "base/bind_helpers.h"
9 #include "base/callback.h" 9 #include "base/callback.h"
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 289 matching lines...) Expand 10 before | Expand all | Expand 10 after
300 void SafeBrowsingService::InitURLRequestContextOnIOThread( 300 void SafeBrowsingService::InitURLRequestContextOnIOThread(
301 net::URLRequestContextGetter* system_url_request_context_getter) { 301 net::URLRequestContextGetter* system_url_request_context_getter) {
302 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); 302 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
303 DCHECK(!url_request_context_.get()); 303 DCHECK(!url_request_context_.get());
304 304
305 scoped_refptr<net::CookieStore> cookie_store( 305 scoped_refptr<net::CookieStore> cookie_store(
306 content::CreatePersistentCookieStore( 306 content::CreatePersistentCookieStore(
307 CookieFilePath(), 307 CookieFilePath(),
308 false, 308 false,
309 NULL, 309 NULL,
310 NULL)); 310 NULL,
311 scoped_refptr<base::SequencedTaskRunner>()));
311 312
312 url_request_context_.reset(new net::URLRequestContext); 313 url_request_context_.reset(new net::URLRequestContext);
313 // |system_url_request_context_getter| may be NULL during tests. 314 // |system_url_request_context_getter| may be NULL during tests.
314 if (system_url_request_context_getter) { 315 if (system_url_request_context_getter) {
315 url_request_context_->CopyFrom( 316 url_request_context_->CopyFrom(
316 system_url_request_context_getter->GetURLRequestContext()); 317 system_url_request_context_getter->GetURLRequestContext());
317 } 318 }
318 url_request_context_->set_cookie_store(cookie_store.get()); 319 url_request_context_->set_cookie_store(cookie_store.get());
319 } 320 }
320 321
(...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after
480 #if defined(FULL_SAFE_BROWSING) 481 #if defined(FULL_SAFE_BROWSING)
481 if (csd_service_.get()) 482 if (csd_service_.get())
482 csd_service_->SetEnabledAndRefreshState(enable); 483 csd_service_->SetEnabledAndRefreshState(enable);
483 if (download_service_.get()) { 484 if (download_service_.get()) {
484 download_service_->SetEnabled( 485 download_service_->SetEnabled(
485 enable && !CommandLine::ForCurrentProcess()->HasSwitch( 486 enable && !CommandLine::ForCurrentProcess()->HasSwitch(
486 switches::kDisableImprovedDownloadProtection)); 487 switches::kDisableImprovedDownloadProtection));
487 } 488 }
488 #endif 489 #endif
489 } 490 }
OLDNEW
« no previous file with comments | « chrome/browser/profiles/profile_impl_io_data.cc ('k') | content/browser/net/sqlite_persistent_cookie_store.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698