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

Unified Diff: chrome/browser/safe_browsing/incident_reporting/binary_integrity_analyzer.cc

Issue 891793002: Take a Profile when adding an incident to the incident reporting service. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: this time Created 5 years, 11 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/safe_browsing/incident_reporting/binary_integrity_analyzer.cc
diff --git a/chrome/browser/safe_browsing/incident_reporting/binary_integrity_analyzer.cc b/chrome/browser/safe_browsing/incident_reporting/binary_integrity_analyzer.cc
index 769289271bf53d50b8ae0d58a201df6c3b8580ee..4473c96e9665af31d4730bb464c72d486cbd2451 100644
--- a/chrome/browser/safe_browsing/incident_reporting/binary_integrity_analyzer.cc
+++ b/chrome/browser/safe_browsing/incident_reporting/binary_integrity_analyzer.cc
@@ -17,6 +17,7 @@
#include "chrome/browser/browser_process.h"
#include "chrome/browser/safe_browsing/binary_feature_extractor.h"
#include "chrome/browser/safe_browsing/incident_reporting/binary_integrity_incident.h"
+#include "chrome/browser/safe_browsing/incident_reporting/incident_receiver.h"
#include "chrome/browser/safe_browsing/safe_browsing_service.h"
#include "chrome/common/safe_browsing/csd.pb.h"
@@ -51,7 +52,7 @@ void RegisterBinaryIntegrityAnalysis() {
#endif
}
-void VerifyBinaryIntegrity(const AddIncidentCallback& callback) {
+void VerifyBinaryIntegrity(scoped_ptr<IncidentReceiver> incident_receiver) {
scoped_refptr<BinaryFeatureExtractor> binary_feature_extractor(
new BinaryFeatureExtractor());
@@ -78,8 +79,8 @@ void VerifyBinaryIntegrity(const AddIncidentCallback& callback) {
incident->set_allocated_signature(signature_info.release());
// Send the report.
- callback.Run(make_scoped_ptr(
- new BinaryIntegrityIncident(incident.Pass())));
+ incident_receiver->AddIncidentForProcess(
+ make_scoped_ptr(new BinaryIntegrityIncident(incident.Pass())));
}
}
}

Powered by Google App Engine
This is Rietveld 408576698