From 01f8bef2ba2a6003cbdebb22bc6c1e7c6240ccd3 Mon Sep 17 00:00:00 2001 From: Xiang Xiao Date: Sat, 19 Jun 2021 23:35:11 +0800 Subject: [PATCH] system/critmon: print info before sleep Signed-off-by: Xiang Xiao --- system/critmon/critmon.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/system/critmon/critmon.c b/system/critmon/critmon.c index 93e5c04e4..6d1bf17e5 100644 --- a/system/critmon/critmon.c +++ b/system/critmon/critmon.c @@ -478,15 +478,15 @@ static int critmon_daemon(int argc, char **argv) while (!g_critmon.stop) { - /* Wait for the next sample interval */ - - sleep(CONFIG_SYSTEM_CRITMONITOR_INTERVAL); - exitcode = critmon_list_once(); if (exitcode != EXIT_SUCCESS) { break; } + + /* Wait for the next sample interval */ + + sleep(CONFIG_SYSTEM_CRITMONITOR_INTERVAL); } /* Stopped */