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

Unified Diff: base/metrics/histogram.cc

Issue 2970873002: Alias |ranges| so it appears in minidump. (Closed)
Patch Set: Created 3 years, 5 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/metrics/histogram.cc
diff --git a/base/metrics/histogram.cc b/base/metrics/histogram.cc
index b7ef10749f86c7387f553137882474497801e311..c2eb63d8876088bc75853beb501a8656b436870d 100644
--- a/base/metrics/histogram.cc
+++ b/base/metrics/histogram.cc
@@ -118,6 +118,7 @@ class Histogram::Factory {
virtual BucketRanges* CreateRanges() {
BucketRanges* ranges = new BucketRanges(bucket_count_ + 1);
Histogram::InitializeBucketRanges(minimum_, maximum_, ranges);
+ base::debug::Alias(&ranges); // TODO(bcwhite): Remove after crbug/586622.
brucedawson 2017/08/17 19:28:00 Be aware that this technique doesn't work very wel
bcwhite 2017/08/18 05:09:01 Yeah... I've noticed that. :-( It would be nice
return ranges;
}
@@ -780,6 +781,7 @@ class LinearHistogram::Factory : public Histogram::Factory {
BucketRanges* CreateRanges() override {
BucketRanges* ranges = new BucketRanges(bucket_count_ + 1);
LinearHistogram::InitializeBucketRanges(minimum_, maximum_, ranges);
+ base::debug::Alias(&ranges); // TODO(bcwhite): Remove after crbug/586622.
return ranges;
}
@@ -975,6 +977,7 @@ class BooleanHistogram::Factory : public Histogram::Factory {
BucketRanges* CreateRanges() override {
BucketRanges* ranges = new BucketRanges(3 + 1);
LinearHistogram::InitializeBucketRanges(1, 2, ranges);
+ base::debug::Alias(&ranges); // TODO(bcwhite): Remove after crbug/586622.
return ranges;
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698