Chromium Code Reviews| Index: chrome/browser/safe_browsing/protocol_manager.h |
| diff --git a/chrome/browser/safe_browsing/protocol_manager.h b/chrome/browser/safe_browsing/protocol_manager.h |
| index 8d3c1191ee31cca201514be8e1954a173377c1c3..e595b1414dffef71719ff06ba54eb2ab6afc80f8 100644 |
| --- a/chrome/browser/safe_browsing/protocol_manager.h |
| +++ b/chrome/browser/safe_browsing/protocol_manager.h |
| @@ -179,6 +179,33 @@ class SafeBrowsingProtocolManager : public net::URLFetcherDelegate, |
| // Record a V4 GetHash result. |
| static void RecordGetV4HashResult(ResultType result_type); |
| + // Enumerate V4 parsing failures for histogramming purposes. DO NOT CHANGE |
|
Nathan Parker
2016/01/15 19:34:43
This could all go in a n anonymous namespace in th
kcarattini
2016/01/20 04:02:05
Done.
|
| + // THE ORDERING OF THESE VALUES. |
| + enum ParseResultType { |
| + // Error parsing the protocol buffer from a string. |
| + PARSE_FROM_STRING_ERROR, |
|
Nathan Parker
2016/01/15 19:34:42
I like to add "= 1.." to each so that you can more
kcarattini
2016/01/20 04:02:05
Done.
|
| + |
| + // A match in the response had an unexpected THREAT_ENTRY_TYPE. |
| + UNEXPECTED_THREAT_ENTRY_TYPE_ERROR, |
| + |
| + // A match in the response had an unexpected THREAT_TYPE. |
| + UNEXPECTED_THREAT_TYPE_ERROR, |
| + |
| + // A match in the response had an unexpected PLATFORM_TYPE. |
| + UNEXPECTED_PLATFORM_TYPE_ERROR, |
| + |
| + // A match in teh response contained no metadata where metadata was |
| + // expected. |
| + NO_METADATA_ERROR, |
| + |
| + // Memory space for histograms is determined by the max. ALWAYS |
| + // ADD NEW VALUES BEFORE THIS ONE. |
| + PARSE_GET_HASH_RESULT_MAX |
| + }; |
| + |
| + // Record parsing errors of a GetHash result. |
| + static void RecordParseGetHashResult(ParseResultType result_type); |
| + |
| // Record HTTP response code when there's no error in fetching an HTTP |
| // request, and the error code, when there is. |
| // |metric_name| is the name of the UMA metric to record the response code or |