[monitoring-plugins] Make some booleans nicer
Lorenz Kästle
git at monitoring-plugins.org
Tue Oct 3 12:30:13 CEST 2023
Module: monitoring-plugins
Branch: check_dhcp_rogue_detection
Commit: 103821efeba4212501475eadcc5a5e5cb2ba9e6f
Author: Lorenz Kästle <12514511+RincewindsHat at users.noreply.github.com>
Date: Tue Oct 3 12:25:48 2023 +0200
URL: https://www.monitoring-plugins.org/repositories/monitoring-plugins/commit/?id=103821e
Make some booleans nicer
---
plugins-root/check_dhcp.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/plugins-root/check_dhcp.c b/plugins-root/check_dhcp.c
index ee794b4..5ba9372 100644
--- a/plugins-root/check_dhcp.c
+++ b/plugins-root/check_dhcp.c
@@ -193,8 +193,8 @@ typedef struct requested_server_struct{
#define ETHERNET_HARDWARE_ADDRESS 1 /* used in htype field of dhcp packet */
#define ETHERNET_HARDWARE_ADDRESS_LENGTH 6 /* length of Ethernet hardware addresses */
-bool unicast = 0; /* unicast mode: mimic a DHCP relay */
-bool exclusive = 0; /* exclusive mode aka "rogue DHCP server detection" */
+bool unicast = false; /* unicast mode: mimic a DHCP relay */
+bool exclusive = false; /* exclusive mode aka "rogue DHCP server detection" */
struct in_addr my_ip; /* our address (required for relay) */
struct in_addr dhcp_ip; /* server to query (if in unicast mode) */
unsigned char client_hardware_address[MAX_DHCP_CHADDR_LENGTH]="";
@@ -1094,7 +1094,7 @@ int call_getopt(int argc, char **argv){
};
int c=0;
- while(1){
+ while(true){
c=getopt_long(argc,argv,"+hVvxt:s:r:t:i:m:u",long_options,&option_index);
if(c==-1||c==EOF||c==1)
More information about the Commits
mailing list