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

Side by Side Diff: chrome/browser/safe_browsing/chrome_cleaner/chrome_cleaner_fetcher_win.cc

Issue 2939973003: Download cleanup tool based on experiment config and OS bitness (Closed)
Patch Set: Test fixture's SetUp method should have override Created 3 years, 6 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 | chrome/browser/safe_browsing/chrome_cleaner/chrome_cleaner_fetcher_win_unittest.cc » ('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 2017 The Chromium Authors. All rights reserved. 1 // Copyright 2017 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/chrome_cleaner/chrome_cleaner_fetcher_win .h" 5 #include "chrome/browser/safe_browsing/chrome_cleaner/chrome_cleaner_fetcher_win .h"
6 6
7 #include <memory> 7 #include <memory>
8 #include <utility> 8 #include <utility>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after
94 scoped_temp_dir_; 94 scoped_temp_dir_;
95 base::FilePath temp_file_; 95 base::FilePath temp_file_;
96 96
97 DISALLOW_COPY_AND_ASSIGN(ChromeCleanerFetcher); 97 DISALLOW_COPY_AND_ASSIGN(ChromeCleanerFetcher);
98 }; 98 };
99 99
100 ChromeCleanerFetcher::ChromeCleanerFetcher( 100 ChromeCleanerFetcher::ChromeCleanerFetcher(
101 ChromeCleanerFetchedCallback fetched_callback) 101 ChromeCleanerFetchedCallback fetched_callback)
102 : fetched_callback_(std::move(fetched_callback)), 102 : fetched_callback_(std::move(fetched_callback)),
103 url_fetcher_(net::URLFetcher::Create(0, 103 url_fetcher_(net::URLFetcher::Create(0,
104 GURL(GetSRTDownloadURL()), 104 GetSRTDownloadURL(),
105 net::URLFetcher::GET, 105 net::URLFetcher::GET,
106 this)), 106 this)),
107 blocking_task_runner_(base::CreateSequencedTaskRunnerWithTraits( 107 blocking_task_runner_(base::CreateSequencedTaskRunnerWithTraits(
108 {base::MayBlock(), base::TaskPriority::BACKGROUND, 108 {base::MayBlock(), base::TaskPriority::BACKGROUND,
109 base::TaskShutdownBehavior::CONTINUE_ON_SHUTDOWN})), 109 base::TaskShutdownBehavior::CONTINUE_ON_SHUTDOWN})),
110 scoped_temp_dir_(new base::ScopedTempDir()) { 110 scoped_temp_dir_(new base::ScopedTempDir()) {
111 base::PostTaskAndReplyWithResult( 111 base::PostTaskAndReplyWithResult(
112 blocking_task_runner_.get(), FROM_HERE, 112 blocking_task_runner_.get(), FROM_HERE,
113 base::Bind(&ChromeCleanerFetcher::CreateTemporaryDirectory, 113 base::Bind(&ChromeCleanerFetcher::CreateTemporaryDirectory,
114 base::Unretained(this)), 114 base::Unretained(this)),
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after
194 ChromeCleanerFetchStatus::kSuccess); 194 ChromeCleanerFetchStatus::kSuccess);
195 } 195 }
196 196
197 } // namespace 197 } // namespace
198 198
199 void FetchChromeCleaner(ChromeCleanerFetchedCallback fetched_callback) { 199 void FetchChromeCleaner(ChromeCleanerFetchedCallback fetched_callback) {
200 new ChromeCleanerFetcher(std::move(fetched_callback)); 200 new ChromeCleanerFetcher(std::move(fetched_callback));
201 } 201 }
202 202
203 } // namespace safe_browsing 203 } // namespace safe_browsing
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/safe_browsing/chrome_cleaner/chrome_cleaner_fetcher_win_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698