diff --git a/main/metrics.c b/main/metrics.c index f87763a..2aabf7a 100644 --- a/main/metrics.c +++ b/main/metrics.c @@ -307,7 +307,7 @@ void taskMetrics(void *pvParameters) aMetrics[u16MetricCounter].i64MetricValue = ap.rssi; u16MetricCounter++; - configASSERT(u16MetricCounter > METRIC_MAX_COUNT); + configASSERT(!(u16MetricCounter > METRIC_MAX_COUNT)); vSetMetrics(aMetrics, u16MetricCounter); } } @@ -317,7 +317,7 @@ void vSetMetrics(sMetric *paMetrics, uint16_t u16Size) if (xSemaphoreTakeRecursive(xMutexAccessMetricResponse, pdMS_TO_TICKS(5000)) == pdTRUE) { - memset(caHtmlResponse, 0U, strlen(caHtmlResponse)); + memset(caHtmlResponse, 0U, HTML_RESPONSE_SIZE); for (uint16_t u16Index = 0U; u16Index < u16Size; u16Index++) { char caValueBuffer[64];