You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by xi...@apache.org on 2022/04/19 10:21:07 UTC

[incubator-nuttx-apps] branch master updated: system/critmon: Fix dead code

This is an automated email from the ASF dual-hosted git repository.

xiaoxiang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-nuttx-apps.git


The following commit(s) were added to refs/heads/master by this push:
     new c7413ee85 system/critmon: Fix dead code
c7413ee85 is described below

commit c7413ee8591e3b74e7b825ae052c72e50966e1b6
Author: Huang Qi <hu...@xiaomi.com>
AuthorDate: Tue Apr 19 17:03:00 2022 +0800

    system/critmon: Fix dead code
    
    Remove branch since errcount could never bigger than 100.
    
    Signed-off-by: Huang Qi <hu...@xiaomi.com>
---
 system/critmon/critmon.c | 7 +------
 1 file changed, 1 insertion(+), 6 deletions(-)

diff --git a/system/critmon/critmon.c b/system/critmon/critmon.c
index c3d60fa79..c5a448ad7 100644
--- a/system/critmon/critmon.c
+++ b/system/critmon/critmon.c
@@ -423,12 +423,7 @@ static int critmon_list_once(void)
 
       fprintf(stderr, "Csection Monitor: Failed to open directory: %s\n",
               CONFIG_SYSTEM_CRITMONITOR_MOUNTPOINT);
-
-      if (++errcount > 100)
-        {
-          fprintf(stderr, "Csection Monitor: Too many errors ... exiting\n");
-          return EXIT_FAILURE;
-        }
+      return EXIT_FAILURE;
     }
 
   /* Read each directory entry */