Chromium Code Reviews| Index: base/metrics/histogram_persistence.cc |
| diff --git a/base/metrics/histogram_persistence.cc b/base/metrics/histogram_persistence.cc |
| index f18d17528354329cd4995615d2451f6a52c59302..c6464e1250fe666598eeeb43ca6df86e26c69ac3 100644 |
| --- a/base/metrics/histogram_persistence.cc |
| +++ b/base/metrics/histogram_persistence.cc |
| @@ -187,6 +187,12 @@ void SetPersistentHistogramMemoryAllocator( |
| // also released, future accesses to those histograms will seg-fault. |
| CHECK(!g_allocator); |
| g_allocator = allocator; |
| + |
| + size_t existing = StatisticsRecorder::NumberOfHistograms(); |
| + if (existing) { |
|
Alexei Svitkine (slow)
2016/03/01 16:41:34
Nit: != 0 for checking numbers.
bcwhite
2016/03/02 19:14:19
Done.
|
| + DLOG(WARNING) << existing |
| + << " histograms were created before persistence was enabled."; |
| + } |
| } |
| PersistentMemoryAllocator* GetPersistentHistogramMemoryAllocator() { |