[Nagiosplug-checkins] nagiosplug/plugins check_ntp.c,1.16,1.17

Holger Weiss hweiss at users.sourceforge.net
Sat Mar 31 19:35:11 CEST 2007


Update of /cvsroot/nagiosplug/nagiosplug/plugins
In directory sc8-pr-cvs7.sourceforge.net:/tmp/cvs-serv4232

Modified Files:
	check_ntp.c 
Log Message:
Add a warning to the verbose output if jitter_request() found no
synchronization source.


Index: check_ntp.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_ntp.c,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -d -r1.16 -r1.17
--- check_ntp.c	31 Mar 2007 17:29:50 -0000	1.16
+++ check_ntp.c	31 Mar 2007 17:35:08 -0000	1.17
@@ -558,7 +558,10 @@
 	}
 	if(verbose) printf("%d candiate peers available\n", num_candidates);
 	if(verbose && syncsource_found) printf("synchronization source found\n");
-	if(! syncsource_found) *status = STATE_WARNING;
+	if(! syncsource_found){
+		*status = STATE_WARNING;
+		if(verbose) printf("warning: no synchronization source found\n");
+	}
 
 
 	for (run=0; run<AVG_NUM; run++){





More information about the Commits mailing list