diff options
author | Craig Tiller <ctiller@google.com> | 2015-06-22 14:31:44 -0700 |
---|---|---|
committer | Craig Tiller <ctiller@google.com> | 2015-06-22 14:31:44 -0700 |
commit | 80ca516640c068f85e8523c50c74d8e790c7bd9c (patch) | |
tree | f1f37e9583dc6430628dd4030c814051f84e2506 /src | |
parent | 8222b19eb14273df8124cb5f46f629836e72f6ad (diff) |
Return dummy data for empty histograms
Diffstat (limited to 'src')
-rw-r--r-- | src/core/support/histogram.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/core/support/histogram.c b/src/core/support/histogram.c index 673affde71..d16ea6c3f7 100644 --- a/src/core/support/histogram.c +++ b/src/core/support/histogram.c @@ -164,7 +164,9 @@ static double threshold_for_count_below(gpr_histogram *h, double count_below) { size_t lower_idx; size_t upper_idx; - GPR_ASSERT(h->count >= 1); + if (h->count == 0) { + return 0.0; + } if (count_below <= 0) { return h->min_seen; |