From 7ba8463506b3d246c246a0caa0d78f0d16b321c6 Mon Sep 17 00:00:00 2001 From: RincewindsHat <12514511+RincewindsHat@users.noreply.github.com> Date: Thu, 19 Oct 2023 11:59:43 +0200 Subject: check_ntp: Initialize intermediate results in any case diff --git a/plugins/check_ntp_peer.c b/plugins/check_ntp_peer.c index d4e5fd9..4fb9018 100644 --- a/plugins/check_ntp_peer.c +++ b/plugins/check_ntp_peer.c @@ -557,7 +557,8 @@ char *perfd_truechimers (int num_truechimers) } int main(int argc, char *argv[]){ - int result, offset_result, stratum, num_truechimers, oresult, jresult, sresult, tresult; + int result, offset_result, stratum, num_truechimers; + int oresult, jresult, sresult, tresult = STATE_UNKNOWN; double offset=0, jitter=0; char *result_line, *perfdata_line; -- cgit v0.10-9-g596f