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

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

Issue 2851493003: Remove unused CookiePreferences from report sender and never send cookies (Closed)
Patch Set: Fix rebase Created 3 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 unified diff | Download patch
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 "base/run_loop.h" 5 #include "base/run_loop.h"
6 #include "chrome/browser/safe_browsing/mock_permission_report_sender.h" 6 #include "chrome/browser/safe_browsing/mock_permission_report_sender.h"
7 #include "content/public/browser/browser_thread.h" 7 #include "content/public/browser/browser_thread.h"
8 8
9 namespace safe_browsing { 9 namespace safe_browsing {
10 10
11 MockPermissionReportSender::MockPermissionReportSender() 11 MockPermissionReportSender::MockPermissionReportSender()
12 : net::ReportSender(nullptr, DO_NOT_SEND_COOKIES), 12 : net::ReportSender(nullptr), number_of_reports_(0) {
13 number_of_reports_(0) {
14 DCHECK(quit_closure_.is_null()); 13 DCHECK(quit_closure_.is_null());
15 } 14 }
16 15
17 MockPermissionReportSender::~MockPermissionReportSender() { 16 MockPermissionReportSender::~MockPermissionReportSender() {
18 } 17 }
19 18
20 void MockPermissionReportSender::Send( 19 void MockPermissionReportSender::Send(
21 const GURL& report_uri, 20 const GURL& report_uri,
22 base::StringPiece content_type, 21 base::StringPiece content_type,
23 base::StringPiece report, 22 base::StringPiece report,
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
64 return latest_content_type_; 63 return latest_content_type_;
65 } 64 }
66 65
67 int MockPermissionReportSender::GetAndResetNumberOfReportsSent() { 66 int MockPermissionReportSender::GetAndResetNumberOfReportsSent() {
68 int new_reports = number_of_reports_; 67 int new_reports = number_of_reports_;
69 number_of_reports_ = 0; 68 number_of_reports_ = 0;
70 return new_reports; 69 return new_reports;
71 } 70 }
72 71
73 } // namespace safe_browsing 72 } // namespace safe_browsing
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698