From: Francesco Chemolli Date: Tue, 13 Dec 2011 18:24:47 +0000 (+0100) Subject: Implemented proper distructor for StatHist X-Git-Tag: BumpSslServerFirst.take05~12^2~120^2~7 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=2a38d23132d18ce990c16b10d866066df1706c11;p=thirdparty%2Fsquid.git Implemented proper distructor for StatHist Started to add some documentation for StatHist. Removed includes of config.h from header files. --- diff --git a/src/StatCounters.h b/src/StatCounters.h index 4e57e70955..c5f64f7933 100644 --- a/src/StatCounters.h +++ b/src/StatCounters.h @@ -31,8 +31,6 @@ #ifndef STATCOUNTERS_H_ #define STATCOUNTERS_H_ -#include "config.h" - #include "StatHist.h" #if USE_CACHE_DIGESTS diff --git a/src/StatHist.cc b/src/StatHist.cc index 7dd385e8cb..c857de3b73 100644 --- a/src/StatHist.cc +++ b/src/StatHist.cc @@ -87,8 +87,16 @@ StatHist::init(int capacity_, hbase_f * val_in_, hbase_f * val_out_, double min_ void StatHist::clear() { - xfree(bins); - bins = NULL; + for(int i=0;i