diff options
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/check_by_ssh.c | 7 | ||||
-rw-r--r-- | plugins/check_dig.c | 9 | ||||
-rw-r--r-- | plugins/check_disk.c | 13 | ||||
-rw-r--r-- | plugins/check_dns.c | 8 | ||||
-rw-r--r-- | plugins/check_dummy.c | 6 | ||||
-rw-r--r-- | plugins/check_fping.c | 4 | ||||
-rw-r--r-- | plugins/check_game.c | 7 | ||||
-rw-r--r-- | plugins/check_hpjd.c | 3 | ||||
-rw-r--r-- | plugins/check_http.c | 3 | ||||
-rw-r--r-- | plugins/check_ide-smart.c | 8 | ||||
-rw-r--r-- | plugins/check_ldap.c | 6 | ||||
-rw-r--r-- | plugins/check_load.c | 4 | ||||
-rw-r--r-- | plugins/check_mrtg.c | 7 | ||||
-rw-r--r-- | plugins/check_mrtgtraf.c | 7 | ||||
-rw-r--r-- | plugins/check_mysql.c | 6 | ||||
-rw-r--r-- | plugins/check_nagios.c | 6 | ||||
-rw-r--r-- | plugins/check_nt.c | 9 | ||||
-rw-r--r-- | plugins/check_nwstat.c | 7 |
18 files changed, 64 insertions, 56 deletions
diff --git a/plugins/check_by_ssh.c b/plugins/check_by_ssh.c index d9fe26e..7080c69 100644 --- a/plugins/check_by_ssh.c +++ b/plugins/check_by_ssh.c | |||
@@ -308,7 +308,7 @@ process_arguments (int argc, char **argv) | |||
308 | asprintf (&remotecmd, "%s;echo STATUS CODE: $?;", remotecmd); | 308 | asprintf (&remotecmd, "%s;echo STATUS CODE: $?;", remotecmd); |
309 | 309 | ||
310 | if (remotecmd == NULL || strlen (remotecmd) <= 1) | 310 | if (remotecmd == NULL || strlen (remotecmd) <= 1) |
311 | usage (_("No remotecmd\n")); | 311 | usage4 (_("No remotecmd")); |
312 | 312 | ||
313 | asprintf (&comm, "%s %s '%s'", comm, hostname, remotecmd); | 313 | asprintf (&comm, "%s %s '%s'", comm, hostname, remotecmd); |
314 | 314 | ||
@@ -409,9 +409,10 @@ $ cat /tmp/foo\n\ | |||
409 | void | 409 | void |
410 | print_usage (void) | 410 | print_usage (void) |
411 | { | 411 | { |
412 | printf (_("\n\ | 412 | printf ("\n\ |
413 | Usage: %s [-f46] [-t timeout] [-i identity] [-l user] -H <host> \n\ | 413 | Usage: %s [-f46] [-t timeout] [-i identity] [-l user] -H <host> \n\ |
414 | -C <command> [-n name] [-s servicelist] [-O outputfile] [-p port]\n"), | 414 | -C <command> [-n name] [-s servicelist] [-O outputfile] [-p port]\n", |
415 | progname); | 415 | progname); |
416 | |||
416 | printf (_(UT_HLP_VRS), progname, progname); | 417 | printf (_(UT_HLP_VRS), progname, progname); |
417 | } | 418 | } |
diff --git a/plugins/check_dig.c b/plugins/check_dig.c index 32bf2c4..823ea01 100644 --- a/plugins/check_dig.c +++ b/plugins/check_dig.c | |||
@@ -353,11 +353,10 @@ print_help (void) | |||
353 | void | 353 | void |
354 | print_usage (void) | 354 | print_usage (void) |
355 | { | 355 | { |
356 | printf (_("\ | 356 | printf ("\ |
357 | Usage: %s -H host -l lookup [-p <server port>] [-T <query type>]\n\ | 357 | Usage: %s -H host -l lookup [-p <server port>] [-T <query type>]\n\ |
358 | [-w <warning interval>] [-c <critical interval>] [-t <timeout>]\n\ | 358 | [-w <warning interval>] [-c <critical interval>] [-t <timeout>]\n\ |
359 | [-a <expected answer address>] [-v]\n"), | 359 | [-a <expected answer address>] [-v]\n", progname); |
360 | progname); | 360 | |
361 | printf (" %s (-h|--help)\n", progname); | 361 | printf (UT_HLP_VRS, progname, progname); |
362 | printf (" %s (-V|--version)\n", progname); | ||
363 | } | 362 | } |
diff --git a/plugins/check_disk.c b/plugins/check_disk.c index c7ea344..70cd548 100644 --- a/plugins/check_disk.c +++ b/plugins/check_disk.c | |||
@@ -322,7 +322,7 @@ process_arguments (int argc, char **argv) | |||
322 | break; | 322 | break; |
323 | } | 323 | } |
324 | else { | 324 | else { |
325 | usage (_("Warning threshold must be integer or percentage!\n")); | 325 | usage4 (_("Warning threshold must be integer or percentage!")); |
326 | } | 326 | } |
327 | case 'c': /* critical threshold */ | 327 | case 'c': /* critical threshold */ |
328 | if (is_intnonneg (optarg)) { | 328 | if (is_intnonneg (optarg)) { |
@@ -339,7 +339,7 @@ process_arguments (int argc, char **argv) | |||
339 | break; | 339 | break; |
340 | } | 340 | } |
341 | else { | 341 | else { |
342 | usage (_("Critical threshold must be integer or percentage!\n")); | 342 | usage4 (_("Critical threshold must be integer or percentage!")); |
343 | } | 343 | } |
344 | case 'u': | 344 | case 'u': |
345 | if (units) | 345 | if (units) |
@@ -636,10 +636,9 @@ and generates an alert if free space is less than one of the threshold values.") | |||
636 | void | 636 | void |
637 | print_usage (void) | 637 | print_usage (void) |
638 | { | 638 | { |
639 | printf (_("\ | 639 | printf ("\ |
640 | Usage: %s -w limit -c limit [-p path | -x device] [-t timeout] [-m] [-e]\n\ | 640 | Usage: %s -w limit -c limit [-p path | -x device] [-t timeout] [-m] [-e]\n\ |
641 | [-v] [-q]\n\ | 641 | [-v] [-q]\n", progname); |
642 | %s (-h|--help)\n\ | 642 | |
643 | %s (-V|--version)\n"), | 643 | printf (UT_HLP_VRS, progname, progname); |
644 | progname, progname, progname); | ||
645 | } | 644 | } |
diff --git a/plugins/check_dns.c b/plugins/check_dns.c index 6dfb09f..579c51a 100644 --- a/plugins/check_dns.c +++ b/plugins/check_dns.c | |||
@@ -425,8 +425,8 @@ specified in /etc/resolv.conf will be used.\n")); | |||
425 | void | 425 | void |
426 | print_usage (void) | 426 | print_usage (void) |
427 | { | 427 | { |
428 | printf (_("\ | 428 | printf ("\ |
429 | Usage: %s -H host [-s server] [-a expected-address] [-A] [-t timeout]\n\ | 429 | Usage: %s -H host [-s server] [-a expected-address] [-A] [-t timeout]\n", progname); |
430 | %s --help\n\ | 430 | |
431 | %s --version\n"), progname, progname, progname); | 431 | printf (UT_HLP_VRS, progname, progname); |
432 | } | 432 | } |
diff --git a/plugins/check_dummy.c b/plugins/check_dummy.c index 6864d02..c621b9f 100644 --- a/plugins/check_dummy.c +++ b/plugins/check_dummy.c | |||
@@ -41,7 +41,7 @@ main (int argc, char **argv) | |||
41 | textdomain (PACKAGE); | 41 | textdomain (PACKAGE); |
42 | 42 | ||
43 | if (argc < 2) | 43 | if (argc < 2) |
44 | usage (_("Incorrect number of arguments supplied\n")); | 44 | usage4 (_("Incorrect number of arguments supplied")); |
45 | else if (strcmp (argv[1], "-V") == 0 || strcmp (argv[1], "--version") == 0) { | 45 | else if (strcmp (argv[1], "-V") == 0 || strcmp (argv[1], "--version") == 0) { |
46 | print_revision (progname, revision); | 46 | print_revision (progname, revision); |
47 | exit (STATE_OK); | 47 | exit (STATE_OK); |
@@ -51,7 +51,7 @@ main (int argc, char **argv) | |||
51 | exit (STATE_OK); | 51 | exit (STATE_OK); |
52 | } | 52 | } |
53 | else if (!is_integer (argv[1])) | 53 | else if (!is_integer (argv[1])) |
54 | usage (_("Arguments to check_dummy must be an integer\n")); | 54 | usage4 (_("Arguments to check_dummy must be an integer")); |
55 | else | 55 | else |
56 | result = atoi (argv[1]); | 56 | result = atoi (argv[1]); |
57 | 57 | ||
@@ -107,5 +107,5 @@ of the <state> argument with optional text.\n")); | |||
107 | void | 107 | void |
108 | print_usage (void) | 108 | print_usage (void) |
109 | { | 109 | { |
110 | printf (_("Usage: %s <integer state> [optional text]\n"), progname); | 110 | printf ("Usage: %s <integer state> [optional text]\n", progname); |
111 | } | 111 | } |
diff --git a/plugins/check_fping.c b/plugins/check_fping.c index 46d4beb..3baf52f 100644 --- a/plugins/check_fping.c +++ b/plugins/check_fping.c | |||
@@ -399,6 +399,6 @@ percentage of packet loss to trigger an alarm state.\n")); | |||
399 | void | 399 | void |
400 | print_usage (void) | 400 | print_usage (void) |
401 | { | 401 | { |
402 | printf (_("Usage: %s <host_address>\n"), progname); | 402 | printf ("Usage: %s <host_address>\n", progname); |
403 | printf (_(UT_HLP_VRS), progname, progname); | 403 | printf (UT_HLP_VRS, progname, progname); |
404 | } | 404 | } |
diff --git a/plugins/check_game.c b/plugins/check_game.c index ea08f9d..a194ab2 100644 --- a/plugins/check_game.c +++ b/plugins/check_game.c | |||
@@ -333,10 +333,11 @@ Notes:\n\ | |||
333 | void | 333 | void |
334 | print_usage (void) | 334 | print_usage (void) |
335 | { | 335 | { |
336 | printf (_("\ | 336 | printf ("\ |
337 | Usage: %s <game> <ip_address> [-p port] [-gf game_field] [-mf map_field]\n\ | 337 | Usage: %s <game> <ip_address> [-p port] [-gf game_field] [-mf map_field]\n\ |
338 | [-pf ping_field]\n"), progname); | 338 | [-pf ping_field]\n", progname); |
339 | printf (_(UT_HLP_VRS), progname, progname); | 339 | |
340 | printf (UT_HLP_VRS, progname, progname); | ||
340 | } | 341 | } |
341 | 342 | ||
342 | /****************************************************************************** | 343 | /****************************************************************************** |
diff --git a/plugins/check_hpjd.c b/plugins/check_hpjd.c index 7ad950a..b9b3f7f 100644 --- a/plugins/check_hpjd.c +++ b/plugins/check_hpjd.c | |||
@@ -400,5 +400,6 @@ print_usage (void) | |||
400 | { | 400 | { |
401 | printf (_("\ | 401 | printf (_("\ |
402 | Usage: %s -H host [-C community]\n"), progname); | 402 | Usage: %s -H host [-C community]\n"), progname); |
403 | printf (_(UT_HLP_VRS), progname, progname); | 403 | |
404 | printf (UT_HLP_VRS, progname, progname); | ||
404 | } | 405 | } |
diff --git a/plugins/check_http.c b/plugins/check_http.c index f6cf507..125052f 100644 --- a/plugins/check_http.c +++ b/plugins/check_http.c | |||
@@ -1497,5 +1497,6 @@ Usage: %s (-H <vhost> | -I <IP-address>) [-u <uri>] [-p <port>]\n\ | |||
1497 | [-s string] [-l] [-r <regex> | -R <case-insensitive regex>]\n\ | 1497 | [-s string] [-l] [-r <regex> | -R <case-insensitive regex>]\n\ |
1498 | [-P string] [-m min_pg_size] [-4|-6] [-N] [-M <age>] [-A string]\n\ | 1498 | [-P string] [-m min_pg_size] [-4|-6] [-N] [-M <age>] [-A string]\n\ |
1499 | [-k string]\n"), progname); | 1499 | [-k string]\n"), progname); |
1500 | printf (_(UT_HLP_VRS), progname, progname); | 1500 | |
1501 | printf (UT_HLP_VRS, progname, progname); | ||
1501 | } | 1502 | } |
diff --git a/plugins/check_ide-smart.c b/plugins/check_ide-smart.c index 6ceebe2..aa74f98 100644 --- a/plugins/check_ide-smart.c +++ b/plugins/check_ide-smart.c | |||
@@ -385,7 +385,7 @@ void | |||
385 | show_help () | 385 | show_help () |
386 | { | 386 | { |
387 | printf (_("\ | 387 | printf (_("\ |
388 | Usage: check_ide-smart [DEVICE] [OPTION]\n\ | 388 | Usage: %s [DEVICE] [OPTION]\n\ |
389 | -d, --device=DEVICE\n\ | 389 | -d, --device=DEVICE\n\ |
390 | Select device DEVICE\n\ | 390 | Select device DEVICE\n\ |
391 | -i, --immediate\n\ | 391 | -i, --immediate\n\ |
@@ -397,9 +397,9 @@ Usage: check_ide-smart [DEVICE] [OPTION]\n\ | |||
397 | -0, --auto-off\n\ | 397 | -0, --auto-off\n\ |
398 | Turn off automatic offline tests\n\ | 398 | Turn off automatic offline tests\n\ |
399 | -n, --net-saint\n\ | 399 | -n, --net-saint\n\ |
400 | Output suitable for Net Saint\n\ | 400 | Output suitable for Net Saint\n", progname); |
401 | -h, --help\n\ | 401 | |
402 | -V, --version\n")); | 402 | printf (UT_HLP_VRS, progname, progname); |
403 | } | 403 | } |
404 | 404 | ||
405 | 405 | ||
diff --git a/plugins/check_ldap.c b/plugins/check_ldap.c index c0b33a8..80c0907 100644 --- a/plugins/check_ldap.c +++ b/plugins/check_ldap.c | |||
@@ -333,10 +333,10 @@ print_help (void) | |||
333 | void | 333 | void |
334 | print_usage (void) | 334 | print_usage (void) |
335 | { | 335 | { |
336 | printf (_("\ | 336 | printf ("\ |
337 | Usage: %s -H <host> -b <base_dn> [-p <port>] [-a <attr>] [-D <binddn>]\n\ | 337 | Usage: %s -H <host> -b <base_dn> [-p <port>] [-a <attr>] [-D <binddn>]\n\ |
338 | [-P <password>] [-w <warn_time>] [-c <crit_time>] [-t timeout]%s\n\ | 338 | [-P <password>] [-w <warn_time>] [-c <crit_time>] [-t timeout]%s\n\ |
339 | (Note: all times are in seconds.)\n"), | 339 | (Note: all times are in seconds.)\n", |
340 | progname, | 340 | progname, |
341 | #ifdef HAVE_LDAP_SET_OPTION | 341 | #ifdef HAVE_LDAP_SET_OPTION |
342 | " [-2|-3] [-4|-6]" | 342 | " [-2|-3] [-4|-6]" |
@@ -345,5 +345,5 @@ Usage: %s -H <host> -b <base_dn> [-p <port>] [-a <attr>] [-D <binddn>]\n\ | |||
345 | #endif | 345 | #endif |
346 | ); | 346 | ); |
347 | 347 | ||
348 | printf (_(UT_HLP_VRS), progname, progname); | 348 | printf (UT_HLP_VRS, progname, progname); |
349 | } | 349 | } |
diff --git a/plugins/check_load.c b/plugins/check_load.c index 803467d..00bfc8a 100644 --- a/plugins/check_load.c +++ b/plugins/check_load.c | |||
@@ -319,7 +319,7 @@ the load average format is the same used by \"uptime\" and \"w\"\n\n")); | |||
319 | void | 319 | void |
320 | print_usage (void) | 320 | print_usage (void) |
321 | { | 321 | { |
322 | printf (_("Usage: %s -w WLOAD1,WLOAD5,WLOAD15 -c CLOAD1,CLOAD5,CLOAD15\n"), | 322 | printf ("Usage: %s -w WLOAD1,WLOAD5,WLOAD15 -c CLOAD1,CLOAD5,CLOAD15\n"), |
323 | progname); | 323 | progname); |
324 | printf (_(UT_HLP_VRS), progname, progname); | 324 | printf (UT_HLP_VRS, progname, progname); |
325 | } | 325 | } |
diff --git a/plugins/check_mrtg.c b/plugins/check_mrtg.c index 7cf7d89..cc4714c 100644 --- a/plugins/check_mrtg.c +++ b/plugins/check_mrtg.c | |||
@@ -379,8 +379,9 @@ this plugin works well for monitoring that kind of data as well.\n\n")); | |||
379 | void | 379 | void |
380 | print_usage (void) | 380 | print_usage (void) |
381 | { | 381 | { |
382 | printf (_("\ | 382 | printf ("\ |
383 | Usage: %s -F log_file -a <AVG | MAX> -v variable -w warning -c critical\n\ | 383 | Usage: %s -F log_file -a <AVG | MAX> -v variable -w warning -c critical\n\ |
384 | [-l label] [-u units] [-e expire_minutes] [-t timeout] [-v]\n"), progname); | 384 | [-l label] [-u units] [-e expire_minutes] [-t timeout] [-v]\n", progname); |
385 | printf (_(UT_HLP_VRS), progname, progname); | 385 | |
386 | printf (UT_HLP_VRS, progname, progname); | ||
386 | } | 387 | } |
diff --git a/plugins/check_mrtgtraf.c b/plugins/check_mrtgtraf.c index f8d6955..69778e3 100644 --- a/plugins/check_mrtgtraf.c +++ b/plugins/check_mrtgtraf.c | |||
@@ -363,8 +363,9 @@ the <iwl> or <owl> thresholds (in Bytes/sec), a WARNING status results.\n\n")); | |||
363 | void | 363 | void |
364 | print_usage (void) | 364 | print_usage (void) |
365 | { | 365 | { |
366 | printf (_("\ | 366 | printf ("\ |
367 | Usage: %s -F <log_file> -a <AVG | MAX> -v <variable> -w <warning_pair> -c <critical_pair>\n\ | 367 | Usage: %s -F <log_file> -a <AVG | MAX> -v <variable> -w <warning_pair> -c <critical_pair>\n\ |
368 | [-e expire_minutes] [-t timeout] [-v]\n"), progname); | 368 | [-e expire_minutes] [-t timeout] [-v]\n", progname); |
369 | printf (_(UT_HLP_VRS), progname, progname); | 369 | |
370 | printf (UT_HLP_VRS, progname, progname); | ||
370 | } | 371 | } |
diff --git a/plugins/check_mysql.c b/plugins/check_mysql.c index 30dce9d..5863e1a 100644 --- a/plugins/check_mysql.c +++ b/plugins/check_mysql.c | |||
@@ -308,8 +308,8 @@ a server listening on MySQL standard port %d will be checked\n"), MYSQL_PORT); | |||
308 | void | 308 | void |
309 | print_usage (void) | 309 | print_usage (void) |
310 | { | 310 | { |
311 | printf (_("\ | 311 | printf ("\ |
312 | Usage: %s [-d database] [-H host] [-P port] [-u user] [-p password] [-S]\n"), | 312 | Usage: %s [-d database] [-H host] [-P port] [-u user] [-p password] [-S]\n", |
313 | progname); | 313 | progname); |
314 | printf (_(UT_HLP_VRS), progname, progname); | 314 | printf (UT_HLP_VRS, progname, progname); |
315 | } | 315 | } |
diff --git a/plugins/check_nagios.c b/plugins/check_nagios.c index 7b312d3..694c069 100644 --- a/plugins/check_nagios.c +++ b/plugins/check_nagios.c | |||
@@ -302,7 +302,9 @@ Example:\n\ | |||
302 | void | 302 | void |
303 | print_usage (void) | 303 | print_usage (void) |
304 | { | 304 | { |
305 | printf (_("\ | 305 | printf ("\ |
306 | Usage: %s -F <status log file> -e <expire_minutes> -C <process_string>\n"), | 306 | Usage: %s -F <status log file> -e <expire_minutes> -C <process_string>\n", |
307 | progname); | 307 | progname); |
308 | |||
309 | printf (UT_HLP_VRS, progname, progname); | ||
308 | } | 310 | } |
diff --git a/plugins/check_nt.c b/plugins/check_nt.c index f142675..2cc45cd 100644 --- a/plugins/check_nt.c +++ b/plugins/check_nt.c | |||
@@ -607,7 +607,7 @@ void preparelist(char *string) { | |||
607 | 607 | ||
608 | void print_help(void) | 608 | void print_help(void) |
609 | { | 609 | { |
610 | print_revision(progname,"$Revision$"); | 610 | print_revision(progname,revision); |
611 | printf (_("\ | 611 | printf (_("\ |
612 | Copyright (c) 2000 Yves Rubin (rubiyz@yahoo.com)\n\n\ | 612 | Copyright (c) 2000 Yves Rubin (rubiyz@yahoo.com)\n\n\ |
613 | This plugin collects data from the NSClient service running on a\n\ | 613 | This plugin collects data from the NSClient service running on a\n\ |
@@ -682,8 +682,9 @@ Windows NT/2000/XP server.\n\n")); | |||
682 | 682 | ||
683 | void print_usage(void) | 683 | void print_usage(void) |
684 | { | 684 | { |
685 | printf(_("\ | 685 | printf("\ |
686 | Usage: %s -H host -v variable [-p port] [-w warning] [-c critical]\n\ | 686 | Usage: %s -H host -v variable [-p port] [-w warning] [-c critical]\n\ |
687 | [-l params] [-d SHOWALL] [-t timeout]\n"), progname); | 687 | [-l params] [-d SHOWALL] [-t timeout]\n", progname); |
688 | printf (_(UT_HLP_VRS), progname, progname); | 688 | |
689 | printf (UT_HLP_VRS, progname, progname); | ||
689 | } | 690 | } |
diff --git a/plugins/check_nwstat.c b/plugins/check_nwstat.c index 9c89ef9..98b06d9 100644 --- a/plugins/check_nwstat.c +++ b/plugins/check_nwstat.c | |||
@@ -987,8 +987,9 @@ Notes:\n\ | |||
987 | 987 | ||
988 | void print_usage(void) | 988 | void print_usage(void) |
989 | { | 989 | { |
990 | printf (_("\ | 990 | printf ("\ |
991 | Usage: %s -H host [-p port] [-v variable] [-w warning] [-c critical]\n\ | 991 | Usage: %s -H host [-p port] [-v variable] [-w warning] [-c critical]\n\ |
992 | [-t timeout].\n"), progname); | 992 | [-t timeout].\n", progname); |
993 | printf (_(UT_HLP_VRS), progname, progname); | 993 | |
994 | printf (UT_HLP_VRS, progname, progname); | ||
994 | } | 995 | } |