summaryrefslogtreecommitdiffstats
path: root/web/attachments/66461-nagios-plugins-1.3.1-check-ntp.patch
diff options
context:
space:
mode:
Diffstat (limited to 'web/attachments/66461-nagios-plugins-1.3.1-check-ntp.patch')
-rw-r--r--web/attachments/66461-nagios-plugins-1.3.1-check-ntp.patch33
1 files changed, 33 insertions, 0 deletions
diff --git a/web/attachments/66461-nagios-plugins-1.3.1-check-ntp.patch b/web/attachments/66461-nagios-plugins-1.3.1-check-ntp.patch
new file mode 100644
index 0000000..32101d8
--- /dev/null
+++ b/web/attachments/66461-nagios-plugins-1.3.1-check-ntp.patch
@@ -0,0 +1,33 @@
1diff -ruN nagios-plugins-1.3.1/plugins-scripts/check_ntp.pl nagios-plugins-1.3.1-new/plugins-scripts/check_ntp.pl
2--- nagios-plugins-1.3.1/plugins-scripts/check_ntp.pl 2003-05-19 11:16:05.000000000 +0100
3+++ nagios-plugins-1.3.1-new/plugins-scripts/check_ntp.pl 2003-07-14 19:46:20.000000000 +0100
4@@ -57,12 +57,19 @@
5 #
6 # Patch for for regex for stratum1 refid.
7
8+BEGIN {
9+ if ($0 =~ m/^(.*?)[\/\\]([^\/\\]+)$/) {
10+ $runtimedir = $1;
11+ $PROGNAME = $2;
12+ }
13+}
14+
15 require 5.004;
16 use POSIX;
17 use strict;
18 use Getopt::Long;
19 use vars qw($opt_V $opt_h $opt_H $opt_w $opt_c $opt_j $opt_k $verbose $PROGNAME $def_jitter);
20-use lib utils.pm;
21+use lib $main::runtimedir;
22 use utils qw($TIMEOUT %ERRORS &print_revision &support);
23
24 $PROGNAME="check_ntp";
25@@ -262,7 +269,7 @@
26 }
27
28 # match sys.peer or pps.peer
29- if (/^(\*|o)([-0-9.\s]+)\s+([-0-9A-Za-z.]+)\s+([-0-9.]+)\s+([lumb]+)\s+([-0-9m.]+)\s+([-0-9.]+)\s+([-0-9.]+)\s+([-0-9.]+)\s+([-0-9.]+)\s+([-0-9.]+)/) {
30+ if (/^(\*|o)([-0-9.\s]+)\s+([-0-9A-Za-z.]+)\s+([-0-9.]+)\s+([lumb]+)\s+([-0-9m.]+)\s+([-0-9.m]+)\s+([-0-9.]+)\s+([-0-9.]+)\s+([-0-9.]+)\s+([-0-9.]+)/) {
31 $syspeer = $2;
32 $stratum = $4;
33 $jitter = $11;