Fix: check ReportSuspension option before print message about action retry

This commit is contained in:
Aleksey Deyneko 2022-03-20 19:49:08 +03:00
parent 53fb41a1eb
commit a7ffb1524f

View File

@ -763,11 +763,13 @@ static void ATTR_NONNULL() actionRetry(action_t * const pThis, wti_t * const pWt
{
setSuspendMessageConfVars(pThis);
actionSetState(pThis, pWti, ACT_STATE_RTRY);
LogMsg(0, RS_RET_SUSPENDED, LOG_WARNING,
"action '%s' suspended (module '%s'), retry %d. There should "
"be messages before this one giving the reason for suspension.",
pThis->pszName, pThis->pMod->pszName,
getActionNbrResRtry(pWti, pThis));
if(pThis->bReportSuspension) {
LogMsg(0, RS_RET_SUSPENDED, LOG_WARNING,
"action '%s' suspended (module '%s'), retry %d. There should "
"be messages before this one giving the reason for suspension.",
pThis->pszName, pThis->pMod->pszName,
getActionNbrResRtry(pWti, pThis));
}
incActionResumeInRow(pWti, pThis);
}