summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThomas Guyot-Sionnest <dermoth@users.sourceforge.net>2008-11-08 16:33:28 (GMT)
committerThomas Guyot-Sionnest <dermoth@users.sourceforge.net>2008-11-08 16:33:28 (GMT)
commit8c1934b7d011769bafde12ac1d80897dfb756944 (patch)
tree86b533da1cfd529d01d76dd7d8a73e5a81874122
parent4e366f82dee33c2f9a2e781d77144b2cf76d7c51 (diff)
downloadmonitoring-plugins-8c1934b7d011769bafde12ac1d80897dfb756944.tar.gz
Add missing long options for check_nt (for use with extra-opts)
Extra-opts (ini files) requires long-options for setting up arguments. Added the missing ones for check_nt so that it can be properly used with extra-opts. git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@2079 f882894a-f735-0410-b71e-b25c423dba1c
-rw-r--r--NEWS3
-rw-r--r--plugins/check_nt.c9
2 files changed, 10 insertions, 2 deletions
diff --git a/NEWS b/NEWS
index 7e8cc7c..438ab67 100644
--- a/NEWS
+++ b/NEWS
@@ -11,7 +11,8 @@ This file documents the major additions and syntax changes between releases.
11 Extra-opts (C plugins) does not allow trailing comments anymore (like N::P) 11 Extra-opts (C plugins) does not allow trailing comments anymore (like N::P)
12 Fixed dependency issue on libtap when ./configure --enable-libtap used. Warning: will install libtap 12 Fixed dependency issue on libtap when ./configure --enable-libtap used. Warning: will install libtap
13 Fixed segfault in extra-opts under some circumstance when reading multiple sections 13 Fixed segfault in extra-opts under some circumstance when reading multiple sections
14 Fix long options parsing in check_disk, check_dns, check_mrtg, check_mrtgtraf and check_tcp. 14 Fix long options parsing in check_disk, check_dns, check_mrtg, check_mrtgtraf and check_tcp
15 Add missing long options for check_nt (for use with extra-opts)
15 check_icmp now reports min and max round trip time perfdata (Steve Rader) 16 check_icmp now reports min and max round trip time perfdata (Steve Rader)
16 Fixed bug where additional headers with redirection caused a segfault (Dieter Van de Walle - 2089159) 17 Fixed bug where additional headers with redirection caused a segfault (Dieter Van de Walle - 2089159)
17 18
diff --git a/plugins/check_nt.c b/plugins/check_nt.c
index 7d20b00..a0e5c11 100644
--- a/plugins/check_nt.c
+++ b/plugins/check_nt.c
@@ -476,6 +476,9 @@ int process_arguments(int argc, char **argv){
476 {"warning", required_argument,0,'w'}, 476 {"warning", required_argument,0,'w'},
477 {"variable", required_argument,0,'v'}, 477 {"variable", required_argument,0,'v'},
478 {"hostname", required_argument,0,'H'}, 478 {"hostname", required_argument,0,'H'},
479 {"params", required_argument,0,'l'},
480 {"secret", required_argument,0,'s'},
481 {"display", required_argument,0,'d'},
479 {"version", no_argument, 0,'V'}, 482 {"version", no_argument, 0,'V'},
480 {"help", no_argument, 0,'h'}, 483 {"help", no_argument, 0,'h'},
481 {0,0,0,0} 484 {0,0,0,0}
@@ -655,7 +658,7 @@ void print_help(void)
655 printf (" %s\n", "-p, --port=INTEGER"); 658 printf (" %s\n", "-p, --port=INTEGER");
656 printf (" %s", _("Optional port number (default: ")); 659 printf (" %s", _("Optional port number (default: "));
657 printf ("%d)\n", PORT); 660 printf ("%d)\n", PORT);
658 printf (" %s\n", "-s <password>"); 661 printf (" %s\n", "-s, --secret=<password>");
659 printf (" %s\n", _("Password needed for the request")); 662 printf (" %s\n", _("Password needed for the request"));
660 printf (" %s\n", "-w, --warning=INTEGER"); 663 printf (" %s\n", "-w, --warning=INTEGER");
661 printf (" %s\n", _("Threshold which will result in a warning status")); 664 printf (" %s\n", _("Threshold which will result in a warning status"));
@@ -663,6 +666,10 @@ void print_help(void)
663 printf (" %s\n", _("Threshold which will result in a critical status")); 666 printf (" %s\n", _("Threshold which will result in a critical status"));
664 printf (" %s\n", "-t, --timeout=INTEGER"); 667 printf (" %s\n", "-t, --timeout=INTEGER");
665 printf (" %s", _("Seconds before connection attempt times out (default: ")); 668 printf (" %s", _("Seconds before connection attempt times out (default: "));
669 printf (" %s\n", "-l, --params=<parameters>");
670 printf (" %s", _("Parameters passed to specified check (see below)"));
671 printf (" %s\n", "-d, --display={SHOWALL}");
672 printf (" %s", _("Display options (currently only SHOWALL works)"));
666 printf ("%d)\n", DEFAULT_SOCKET_TIMEOUT); 673 printf ("%d)\n", DEFAULT_SOCKET_TIMEOUT);
667 printf (" %s\n", "-h, --help"); 674 printf (" %s\n", "-h, --help");
668 printf (" %s\n", _("Print this help screen")); 675 printf (" %s\n", _("Print this help screen"));