[monitoring-plugins] check_dhcp: remove unnecessary casts
Lorenz Kästle
git at monitoring-plugins.org
Sun Jul 26 11:00:15 CEST 2026
Module: monitoring-plugins
Branch: master
Commit: 90b3a6b3920f3f3b5276dfcf231b2b7729ed0e0b
Author: Lorenz Kästle <lorenz at vulgrim.de>
Date: Fri Jul 17 14:26:41 2026 +0200
URL: https://www.monitoring-plugins.org/repositories/monitoring-plugins/commit/?id=90b3a6b3
check_dhcp: remove unnecessary casts
---
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 28bffbfd..aa1bdc30 100644
--- a/plugins-root/check_dhcp.c
+++ b/plugins-root/check_dhcp.c
@@ -969,17 +969,17 @@ add_dhcp_offer_wrapper add_dhcp_offer(struct in_addr source, dhcp_packet *offer_
if (dhcp_lease_time == DHCP_INFINITE_TIME) {
printf(_("Lease Time: Infinite\n"));
} else {
- printf(_("Lease Time: %lu seconds\n"), (unsigned long)dhcp_lease_time);
+ printf(_("Lease Time: %" PRIu32 " seconds\n"), dhcp_lease_time);
}
if (dhcp_renewal_time == DHCP_INFINITE_TIME) {
printf(_("Renewal Time: Infinite\n"));
} else {
- printf(_("Renewal Time: %lu seconds\n"), (unsigned long)dhcp_renewal_time);
+ printf(_("Renewal Time: %" PRIu32 " seconds\n"), dhcp_renewal_time);
}
if (dhcp_rebinding_time == DHCP_INFINITE_TIME) {
printf(_("Rebinding Time: Infinite\n"));
}
- printf(_("Rebinding Time: %lu seconds\n"), (unsigned long)dhcp_rebinding_time);
+ printf(_("Rebinding Time: %" PRIu32 " seconds\n"), dhcp_rebinding_time);
}
new_offer = (dhcp_offer *)malloc(sizeof(dhcp_offer));
More information about the Commits
mailing list