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

Side by Side Diff: chrome/browser/safe_browsing/incident_reporting/variations_seed_signature_incident.cc

Issue 856543004: Replace incident type handlers with implementations of Incident. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: 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 unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "chrome/browser/safe_browsing/incident_reporting/variations_seed_signat ure_incident.h"
6
7 #include "base/logging.h"
8 #include "chrome/browser/safe_browsing/incident_reporting/incident_handler_util. h"
9 #include "chrome/common/safe_browsing/csd.pb.h"
10
11 namespace safe_browsing {
12
13 VariationsSeedSignatureIncident::VariationsSeedSignatureIncident(
14 scoped_ptr<
15 ClientIncidentReport_IncidentData_VariationsSeedSignatureIncident>
16 variations_seed_signature_incident) {
17 DCHECK(variations_seed_signature_incident);
18 DCHECK(variations_seed_signature_incident->has_variations_seed_signature());
19 payload()->set_allocated_variations_seed_signature(
20 variations_seed_signature_incident.release());
21 }
22
23 VariationsSeedSignatureIncident::~VariationsSeedSignatureIncident() {
24 }
25
26 IncidentType VariationsSeedSignatureIncident::GetType() const {
27 return IncidentType::VARIATIONS_SEED_SIGNATURE;
28 }
29
30 std::string VariationsSeedSignatureIncident::GetKey() const {
31 return "variations_seed_signature";
32 }
33
34 uint32_t VariationsSeedSignatureIncident::ComputeDigest() const {
35 return HashMessage(payload()->variations_seed_signature());
36 }
37
38 } // namespace safe_browsing
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698