@cryptotaxi247 / netdata-1 / commits / a5cbaf4c2

detect too big updates correctly

Costa Tsaousis (ktsaou) committed Mar 19, 2015 at 11:19 UTC a5cbaf4c29bcaf61ce4f2bde396da18b36e10c27
1 file changed +1 -1
src/rrd.c
+1 -1
@@ -645,7 +645,7 @@ unsigned long long rrd_stats_done(RRD_STATS *st)
645 // a read lock is OK here
646 pthread_rwlock_rdlock(&st->rwlock);
647
648 - if(st->usec_since_last_update > st->entries * st->update_every * 1000000ULL) {
648 + if(st->usec_since_last_update > st->entries * st->update_every * 1000000ULL || usecdiff(&st->last_collected_time, &st->last_updated) > st->entries * st->update_every * 1000000ULL) {
649 info("History of chart %s too old. Reseting chart.", st->name);
650 rrd_stats_reset(st);
651 st->usec_since_last_update = st->update_every * 1000000ULL;