Merge pull request #5 from lcp/fix_stddev

Initialize sum_sq before using it
This commit is contained in:
Jacob Leverich 2014-08-15 13:40:47 -07:00
commit cfd4688510

View File

@ -23,7 +23,7 @@ public:
double sum_sq;
LogHistogramSampler() = delete;
LogHistogramSampler(int _bins) : sum(0.0) {
LogHistogramSampler(int _bins) : sum(0.0), sum_sq(0.0) {
assert(_bins > 0);
bins.resize(_bins + 1, 0);