diff options
author | Rainer Gerhards <rgerhards@adiscon.com> | 2013-06-15 10:15:00 +0200 |
---|---|---|
committer | Rainer Gerhards <rgerhards@adiscon.com> | 2013-06-15 10:15:00 +0200 |
commit | 44a45748ce5a17e39da9af29fe9a8af9ba821c28 (patch) | |
tree | c075cb49acdccee1600fdfc85f389f7e4300a6b9 /runtime/ratelimit.c | |
parent | 99ce83604aed4dbaa46045335b527d09e41a846d (diff) | |
parent | f0f1a53a1650eb00e8f071d269bbe63bca285169 (diff) | |
download | rsyslog-44a45748ce5a17e39da9af29fe9a8af9ba821c28.tar.gz rsyslog-44a45748ce5a17e39da9af29fe9a8af9ba821c28.tar.bz2 rsyslog-44a45748ce5a17e39da9af29fe9a8af9ba821c28.zip |
Merge branch 'v7-stable'
Diffstat (limited to 'runtime/ratelimit.c')
-rw-r--r-- | runtime/ratelimit.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/runtime/ratelimit.c b/runtime/ratelimit.c index ec248550..6e1df3e2 100644 --- a/runtime/ratelimit.c +++ b/runtime/ratelimit.c @@ -128,8 +128,8 @@ tellLostCnt(ratelimit_t *ratelimit) snprintf((char*)msgbuf, sizeof(msgbuf), "%s: %u messages lost due to rate-limiting", ratelimit->name, ratelimit->missed); - logmsgInternal(RS_RET_RATE_LIMITED, LOG_SYSLOG|LOG_INFO, msgbuf, 0); ratelimit->missed = 0; + logmsgInternal(RS_RET_RATE_LIMITED, LOG_SYSLOG|LOG_INFO, msgbuf, 0); } } @@ -157,9 +157,9 @@ withinRatelimit(ratelimit_t *ratelimit, time_t tt) /* resume if we go out of out time window */ if(tt > ratelimit->begin + ratelimit->interval) { - tellLostCnt(ratelimit); ratelimit->begin = 0; ratelimit->done = 0; + tellLostCnt(ratelimit); } /* do actual limit check */ |