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

Unified Diff: base/metrics/sample_vector_unittest.cc

Issue 2853853002: Fix overflow when logging MaxInt32 to a sparse histogram. (Closed)
Patch Set: Address comments. Created 3 years, 8 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
« no previous file with comments | « base/metrics/sample_vector.cc ('k') | base/metrics/sparse_histogram.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/metrics/sample_vector_unittest.cc
diff --git a/base/metrics/sample_vector_unittest.cc b/base/metrics/sample_vector_unittest.cc
index 2d77d2376b83a7442fd2e0929e5e21d832d6ba88..864a44dcbf3a7fac5de6e8037e9f955f9959f29f 100644
--- a/base/metrics/sample_vector_unittest.cc
+++ b/base/metrics/sample_vector_unittest.cc
@@ -215,7 +215,7 @@ TEST(SampleVectorIteratorTest, IterateTest) {
size_t index;
HistogramBase::Sample min;
- HistogramBase::Sample max;
+ int64_t max;
HistogramBase::Count count;
it.Get(&min, &max, &count);
EXPECT_EQ(0, min);
@@ -271,7 +271,7 @@ TEST(SampleVectorIteratorDeathTest, IterateDoneTest) {
EXPECT_TRUE(it->Done());
HistogramBase::Sample min;
- HistogramBase::Sample max;
+ int64_t max;
HistogramBase::Count count;
EXPECT_DCHECK_DEATH(it->Get(&min, &max, &count));
« no previous file with comments | « base/metrics/sample_vector.cc ('k') | base/metrics/sparse_histogram.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698