[04/11] misc: syslog: Use bool for connected

Message ID 20210412211113.393120-4-adhemerval.zanella@linaro.org
State Committed
Headers
Series [01/11] support: Add xmkfifo |

Commit Message

Adhemerval Zanella April 12, 2021, 9:11 p.m. UTC
  Checked on x86_64-linux-gnu.
---
 misc/syslog.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
  

Comments

Andreas Schwab April 14, 2021, 2:54 p.m. UTC | #1
Ok.

Andreas.
  

Patch

diff --git a/misc/syslog.c b/misc/syslog.c
index 2ec986811d..668b4c852b 100644
--- a/misc/syslog.c
+++ b/misc/syslog.c
@@ -58,7 +58,7 @@ 
 
 static int LogType = SOCK_DGRAM;        /* Type of socket connection  */
 static int LogFile = -1;                /* fd for log  */
-static int connected;                   /* Have done connect */
+static bool connected;                  /* Have done connect */
 static int LogStat;                     /* Status bits, set by openlog()  */
 static const char *LogTag;              /* String to tag the entry with  */
 static int LogFacility = LOG_USER;      /* Default facility code  */
@@ -374,7 +374,7 @@  openlog_internal (const char *ident, int logstat, int logfac)
                 }
             }
           else
-            connected = 1;
+            connected = true;
         }
       break;
     }
@@ -408,7 +408,7 @@  closelog_internal (void)
 
   __close (LogFile);
   LogFile = -1;
-  connected = 0;
+  connected = false;
 }
 
 void