mirror of
https://github.com/rsyslog/rsyslog.git
synced 2025-12-19 23:10:41 +01:00
bugfix: prevent another endless loop in the ratelimiter
The message that reports how many messages were lost due to ratelimiting was sent before reseting the state that led to it. If it itself got ratelimited, this could lead to an endless loop.
This commit is contained in:
parent
940327046c
commit
2547716dbc
@ -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);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user