[Nagiosplug-checkins] nagiosplug/plugins check_apt.c, 1.9, 1.10 check_by_ssh.c, 1.40, 1.41 check_dig.c, 1.45, 1.46 check_dns.c, 1.54, 1.55 check_fping.c, 1.27, 1.28 check_game.c, 1.28, 1.29 check_hpjd.c, 1.34, 1.35 check_http.c, 1.98, 1.99 check_ide_smart.c, 1.12, 1.13 check_ldap.c, 1.34, 1.35 check_load.c, 1.32, 1.33 check_mrtg.c, 1.28, 1.29 check_mrtgtraf.c, 1.25, 1.26 check_mysql.c, 1.33, 1.34 check_mysql_query.c, 1.5, 1.6 check_nagios.c, 1.31, 1.32 check_nt.c, 1.45, 1.46 check_ntp.c, 1.12, 1.13 check_nwstat.c, 1.34, 1.35 check_overcr.c, 1.21, 1.22 check_pgsql.c, 1.34, 1.35 check_ping.c, 1.57, 1.58 check_procs.c, 1.56, 1.57 check_radius.c, 1.24, 1.25 check_real.c, 1.28, 1.29 check_smtp.c, 1.55, 1.56 check_snmp.c, 1.67, 1.68 check_ssh.c, 1.31, 1.32 check_swap.c, 1.57, 1.58 check_tcp.c, 1.81, 1.82 check_time.c, 1.28, 1.29 check_ups.c, 1.30, 1.31 check_users.c, 1.21, 1.22 negate.c, 1.26, 1.27 urlize.c, 1.21, 1.22 utils.c, 1.50, 1.51 utils.h, 1.32, 1.33

Holger Weiss hweiss at users.sourceforge.net
Sun Jan 28 22:46:43 CET 2007


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

Modified Files:
	check_apt.c check_by_ssh.c check_dig.c check_dns.c 
	check_fping.c check_game.c check_hpjd.c check_http.c 
	check_ide_smart.c check_ldap.c check_load.c check_mrtg.c 
	check_mrtgtraf.c check_mysql.c check_mysql_query.c 
	check_nagios.c check_nt.c check_ntp.c check_nwstat.c 
	check_overcr.c check_pgsql.c check_ping.c check_procs.c 
	check_radius.c check_real.c check_smtp.c check_snmp.c 
	check_ssh.c check_swap.c check_tcp.c check_time.c check_ups.c 
	check_users.c negate.c urlize.c utils.c utils.h 
Log Message:
Don't try to print `optarg' (which will be a NULL pointer) if an unknown
command line option was used, as this leads to a segfault on some
systems.  The unknown option will be printed by getopt(3) anyway.  So,
simply call print_usage() and exit UNKNOWN via the new usage5() instead.


Index: check_tcp.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_tcp.c,v
retrieving revision 1.81
retrieving revision 1.82
diff -u -d -r1.81 -r1.82
--- check_tcp.c	23 Jan 2007 17:20:43 -0000	1.81
+++ check_tcp.c	28 Jan 2007 21:46:40 -0000	1.82
@@ -443,7 +443,7 @@
 
 		switch (c) {
 		case '?':                 /* print short usage statement if args not parsable */
-			usage2 (_("Unknown argument"), optarg);
+			usage5 ();
 		case 'h':                 /* help */
 			print_help ();
 			exit (STATE_OK);

Index: check_overcr.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_overcr.c,v
retrieving revision 1.21
retrieving revision 1.22
diff -u -d -r1.21 -r1.22
--- check_overcr.c	19 Oct 2006 00:25:16 -0000	1.21
+++ check_overcr.c	28 Jan 2007 21:46:40 -0000	1.22
@@ -341,7 +341,7 @@
 
 		switch (c) {
 		case '?':									/* print short usage statement if args not parsable */
-			usage2 (_("Unknown argument"), optarg);
+			usage5 ();
 		case 'h':									/* help */
 			print_help ();
 			exit (STATE_OK);

Index: check_mrtgtraf.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_mrtgtraf.c,v
retrieving revision 1.25
retrieving revision 1.26
diff -u -d -r1.25 -r1.26
--- check_mrtgtraf.c	19 Oct 2006 00:25:16 -0000	1.25
+++ check_mrtgtraf.c	28 Jan 2007 21:46:40 -0000	1.26
@@ -277,7 +277,7 @@
 			print_help ();
 			exit (STATE_OK);
 		case '?':									/* help */
-			usage2 (_("Unknown argument"), optarg);
+			usage5 ();
 		}
 	}
 

Index: check_http.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_http.c,v
retrieving revision 1.98
retrieving revision 1.99
diff -u -d -r1.98 -r1.99
--- check_http.c	20 Jan 2007 07:18:12 -0000	1.98
+++ check_http.c	28 Jan 2007 21:46:40 -0000	1.99
@@ -225,7 +225,7 @@
 
     switch (c) {
     case '?': /* usage */
-      usage2 (_("Unknown argument"), optarg);
+      usage5 ();
       break;
     case 'h': /* help */
       print_help ();

Index: check_time.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_time.c,v
retrieving revision 1.28
retrieving revision 1.29
diff -u -d -r1.28 -r1.29
--- check_time.c	19 Oct 2006 23:53:28 -0000	1.28
+++ check_time.c	28 Jan 2007 21:46:40 -0000	1.29
@@ -232,7 +232,7 @@
 
 		switch (c) {
 		case '?':									/* print short usage statement if args not parsable */
-			usage2 (_("Unknown argument"), optarg);
+			usage5 ();
 		case 'h':									/* help */
 			print_help ();
 			exit (STATE_OK);

Index: check_ssh.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_ssh.c,v
retrieving revision 1.31
retrieving revision 1.32
diff -u -d -r1.31 -r1.32
--- check_ssh.c	23 Jan 2007 18:34:45 -0000	1.31
+++ check_ssh.c	28 Jan 2007 21:46:40 -0000	1.32
@@ -128,7 +128,7 @@
 
 		switch (c) {
 		case '?':									/* help */
-			usage2 (_("Unknown argument"), optarg);
+			usage5 ();
 		case 'V':									/* version */
 			print_revision (progname, revision);
 			exit (STATE_OK);

Index: check_mysql_query.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_mysql_query.c,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -d -r1.5 -r1.6
--- check_mysql_query.c	19 Oct 2006 00:25:16 -0000	1.5
+++ check_mysql_query.c	28 Jan 2007 21:46:40 -0000	1.6
@@ -240,7 +240,7 @@
 			critical = optarg;
 			break;
 		case '?':									/* help */
-			usage2 (_("Unknown argument"), optarg);
+			usage5 ();
 		}
 	}
 

Index: check_swap.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_swap.c,v
retrieving revision 1.57
retrieving revision 1.58
diff -u -d -r1.57 -r1.58
--- check_swap.c	7 Dec 2006 16:07:42 -0000	1.57
+++ check_swap.c	28 Jan 2007 21:46:40 -0000	1.58
@@ -468,7 +468,7 @@
 			print_help ();
 			exit (STATE_OK);
 		case '?':									/* error */
-			usage2 (_("Unknown argument"), optarg);
+			usage5 ();
 		}
 	}
 

Index: check_hpjd.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_hpjd.c,v
retrieving revision 1.34
retrieving revision 1.35
diff -u -d -r1.34 -r1.35
--- check_hpjd.c	19 Oct 2006 00:25:16 -0000	1.34
+++ check_hpjd.c	28 Jan 2007 21:46:40 -0000	1.35
@@ -351,7 +351,7 @@
 			print_help ();
 			exit (STATE_OK);
 		case '?':									/* help */
-			usage2 (_("Unknown argument"), optarg);
+			usage5 ();
 		}
 	}
 

Index: check_snmp.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_snmp.c,v
retrieving revision 1.67
retrieving revision 1.68
diff -u -d -r1.67 -r1.68
--- check_snmp.c	20 Oct 2006 07:53:31 -0000	1.67
+++ check_snmp.c	28 Jan 2007 21:46:40 -0000	1.68
@@ -444,7 +444,7 @@
 
 		switch (c) {
 		case '?':	/* usage */
-			usage2 (_("Unknown argument"), optarg);
+			usage5 ();
 		case 'h':	/* help */
 			print_help ();
 			exit (STATE_OK); 

Index: check_real.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_real.c,v
retrieving revision 1.28
retrieving revision 1.29
diff -u -d -r1.28 -r1.29
--- check_real.c	4 Jan 2007 11:51:04 -0000	1.28
+++ check_real.c	28 Jan 2007 21:46:40 -0000	1.29
@@ -368,7 +368,7 @@
 			print_help ();
 			exit (STATE_OK);
 		case '?':									/* usage */
-			usage2 (_("Unknown argument"), optarg);
+			usage5 ();
 		}
 	}
 

Index: check_mysql.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_mysql.c,v
retrieving revision 1.33
retrieving revision 1.34
diff -u -d -r1.33 -r1.34
--- check_mysql.c	19 Oct 2006 00:25:16 -0000	1.33
+++ check_mysql.c	28 Jan 2007 21:46:40 -0000	1.34
@@ -308,7 +308,7 @@
 			verbose++;
 			break;
 		case '?':									/* help */
-			usage2 (_("Unknown argument"), optarg);
+			usage5 ();
 		}
 	}
 

Index: check_ldap.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_ldap.c,v
retrieving revision 1.34
retrieving revision 1.35
diff -u -d -r1.34 -r1.35
--- check_ldap.c	20 Jan 2007 07:18:12 -0000	1.34
+++ check_ldap.c	28 Jan 2007 21:46:40 -0000	1.35
@@ -325,7 +325,7 @@
 #endif
 			break;
 		default:
-			usage2 (_("Unknown argument"), optarg);
+			usage5 ();
 		}
 	}
 

Index: check_ups.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_ups.c,v
retrieving revision 1.30
retrieving revision 1.31
diff -u -d -r1.30 -r1.31
--- check_ups.c	19 Oct 2006 23:53:28 -0000	1.30
+++ check_ups.c	28 Jan 2007 21:46:41 -0000	1.31
@@ -494,7 +494,7 @@
 
 		switch (c) {
 		case '?':									/* help */
-			usage2 (_("Unknown argument"), optarg);
+			usage5 ();
 		case 'H':									/* hostname */
 			if (is_host (optarg)) {
 				server_address = optarg;

Index: check_nwstat.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_nwstat.c,v
retrieving revision 1.34
retrieving revision 1.35
diff -u -d -r1.34 -r1.35
--- check_nwstat.c	19 Oct 2006 00:25:16 -0000	1.34
+++ check_nwstat.c	28 Jan 2007 21:46:40 -0000	1.35
@@ -1355,7 +1355,7 @@
 		switch (c)
 			{
 			case '?': /* print short usage statement if args not parsable */
-			usage2 (_("Unknown argument"), optarg);
+			usage5 ();
 			case 'h': /* help */
 				print_help();
 				exit(STATE_OK);

Index: check_pgsql.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_pgsql.c,v
retrieving revision 1.34
retrieving revision 1.35
diff -u -d -r1.34 -r1.35
--- check_pgsql.c	19 Oct 2006 00:25:16 -0000	1.34
+++ check_pgsql.c	28 Jan 2007 21:46:40 -0000	1.35
@@ -225,7 +225,7 @@
 
 		switch (c) {
 		case '?':     /* usage */
-			usage2 (_("Unknown argument"), optarg);
+			usage5 ();
 		case 'h':     /* help */
 			print_help ();
 			exit (STATE_OK);

Index: check_procs.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_procs.c,v
retrieving revision 1.56
retrieving revision 1.57
diff -u -d -r1.56 -r1.57
--- check_procs.c	24 Jan 2007 23:18:05 -0000	1.56
+++ check_procs.c	28 Jan 2007 21:46:40 -0000	1.57
@@ -359,7 +359,7 @@
 
 		switch (c) {
 		case '?':									/* help */
-			usage2 (_("Unknown argument"), optarg);
+			usage5 ();
 		case 'h':									/* help */
 			print_help ();
 			exit (STATE_OK);

Index: negate.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/negate.c,v
retrieving revision 1.26
retrieving revision 1.27
diff -u -d -r1.26 -r1.27
--- negate.c	19 Oct 2006 23:53:28 -0000	1.26
+++ negate.c	28 Jan 2007 21:46:41 -0000	1.27
@@ -189,7 +189,7 @@
 
 		switch (c) {
 		case '?':     /* help */
-			usage2 (_("Unknown argument"), optarg);
+			usage5 ();
 			break;
 		case 'h':     /* help */
 			print_help ();

Index: check_nt.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_nt.c,v
retrieving revision 1.45
retrieving revision 1.46
diff -u -d -r1.45 -r1.46
--- check_nt.c	24 Oct 2006 21:48:22 -0000	1.45
+++ check_nt.c	28 Jan 2007 21:46:40 -0000	1.46
@@ -492,7 +492,7 @@
 		switch (c)
 			{
 			case '?': /* print short usage statement if args not parsable */
-			usage2 (_("Unknown argument"), optarg);
+			usage5 ();
 			case 'h': /* help */
 				print_help();
 				exit(STATE_OK);

Index: check_ide_smart.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_ide_smart.c,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -d -r1.12 -r1.13
--- check_ide_smart.c	19 Oct 2006 00:25:16 -0000	1.12
+++ check_ide_smart.c	28 Jan 2007 21:46:40 -0000	1.13
@@ -212,7 +212,7 @@
 			print_revision (progname, revision);
 			return STATE_OK;
 		default:
-			usage2 (_("Unknown argument"), optarg);
+			usage5 ();
 		}
 	}
 

Index: check_load.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_load.c,v
retrieving revision 1.32
retrieving revision 1.33
diff -u -d -r1.32 -r1.33
--- check_load.c	19 Oct 2006 00:25:16 -0000	1.32
+++ check_load.c	28 Jan 2007 21:46:40 -0000	1.33
@@ -236,7 +236,7 @@
 			print_help ();
 			exit (STATE_OK);
 		case '?':									/* help */
-			usage2 (_("Unknown argument"), optarg);
+			usage5 ();
 		}
 	}
 

Index: urlize.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/urlize.c,v
retrieving revision 1.21
retrieving revision 1.22
diff -u -d -r1.21 -r1.22
--- urlize.c	19 Oct 2006 23:53:28 -0000	1.21
+++ urlize.c	28 Jan 2007 21:46:41 -0000	1.22
@@ -100,7 +100,7 @@
 			break;
 		case '?':
 		default:
-			usage2 (_("Unknown argument"), optarg);
+			usage5 ();
 		}
 	}
 

Index: check_mrtg.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_mrtg.c,v
retrieving revision 1.28
retrieving revision 1.29
diff -u -d -r1.28 -r1.29
--- check_mrtg.c	20 Oct 2006 07:39:35 -0000	1.28
+++ check_mrtg.c	28 Jan 2007 21:46:40 -0000	1.29
@@ -243,7 +243,7 @@
 			print_help ();
 			exit (STATE_OK);
 		case '?':									/* help */
-			usage2 (_("Unknown argument"), optarg);
+			usage5 ();
 		}
 	}
 

Index: check_ntp.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_ntp.c,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -d -r1.12 -r1.13
--- check_ntp.c	20 Jan 2007 10:59:25 -0000	1.12
+++ check_ntp.c	28 Jan 2007 21:46:40 -0000	1.13
@@ -694,7 +694,7 @@
 			break;
 		case '?':
 			/* print short usage statement if args not parsable */
-			usage2 (_("Unknown argument"), optarg);
+			usage5 ();
 			break;
 		}
 	}

Index: check_apt.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_apt.c,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -d -r1.9 -r1.10
--- check_apt.c	22 Oct 2006 22:03:31 -0000	1.9
+++ check_apt.c	28 Jan 2007 21:46:40 -0000	1.10
@@ -201,7 +201,7 @@
 			break;
 		default:
 			/* print short usage statement if args not parsable */
-			usage_va(_("Unknown argument - %s"), optarg);
+			usage5();
 		}
 	}
 

Index: check_radius.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_radius.c,v
retrieving revision 1.24
retrieving revision 1.25
diff -u -d -r1.24 -r1.25
--- check_radius.c	23 Jan 2007 16:42:01 -0000	1.24
+++ check_radius.c	28 Jan 2007 21:46:40 -0000	1.25
@@ -235,7 +235,7 @@
 
 		switch (c) {
 		case '?':									/* print short usage statement if args not parsable */
-			usage2 (_("Unknown argument"), optarg);
+			usage5 ();
 		case 'h':									/* help */
 			print_help ();
 			exit (OK);

Index: check_by_ssh.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_by_ssh.c,v
retrieving revision 1.40
retrieving revision 1.41
diff -u -d -r1.40 -r1.41
--- check_by_ssh.c	22 Jan 2007 04:05:37 -0000	1.40
+++ check_by_ssh.c	28 Jan 2007 21:46:40 -0000	1.41
@@ -262,7 +262,7 @@
 			asprintf (&comm, "%s -%c", comm, c);
 			break;
 		default:									/* help */
-			usage_va(_("Unknown argument - %s"), optarg);
+			usage5();
 		}
 	}
 

Index: check_fping.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_fping.c,v
retrieving revision 1.27
retrieving revision 1.28
diff -u -d -r1.27 -r1.28
--- check_fping.c	19 Oct 2006 00:25:16 -0000	1.27
+++ check_fping.c	28 Jan 2007 21:46:40 -0000	1.28
@@ -258,7 +258,7 @@
 
     switch (c) {
     case '?':                 /* print short usage statement if args not parsable */
-      usage2 (_("Unknown argument"), optarg);
+      usage5 ();
     case 'h':                 /* help */
       print_help ();
       exit (STATE_OK);

Index: check_users.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_users.c,v
retrieving revision 1.21
retrieving revision 1.22
diff -u -d -r1.21 -r1.22
--- check_users.c	19 Oct 2006 23:53:28 -0000	1.21
+++ check_users.c	28 Jan 2007 21:46:41 -0000	1.22
@@ -156,7 +156,7 @@
 
 		switch (c) {
 		case '?':									/* print short usage statement if args not parsable */
-			usage2 (_("Unknown argument"), optarg);
+			usage5 ();
 		case 'h':									/* help */
 			print_help ();
 			exit (STATE_OK);

Index: check_ping.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_ping.c,v
retrieving revision 1.57
retrieving revision 1.58
diff -u -d -r1.57 -r1.58
--- check_ping.c	6 Jan 2007 06:41:47 -0000	1.57
+++ check_ping.c	28 Jan 2007 21:46:40 -0000	1.58
@@ -211,7 +211,7 @@
 
 		switch (c) {
 		case '?':	/* usage */
-			usage2 (_("Unknown argument"), optarg);
+			usage5 ();
 		case 'h':	/* help */
 			print_help ();
 			exit (STATE_OK);

Index: check_dns.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_dns.c,v
retrieving revision 1.54
retrieving revision 1.55
diff -u -d -r1.54 -r1.55
--- check_dns.c	19 Oct 2006 00:25:16 -0000	1.54
+++ check_dns.c	28 Jan 2007 21:46:40 -0000	1.55
@@ -370,7 +370,7 @@
       critical = optarg;
       break;
     default: /* args not parsable */
-      usage_va(_("Unknown argument - %s"), optarg);
+      usage5();
     }
   }
 

Index: utils.h
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/utils.h,v
retrieving revision 1.32
retrieving revision 1.33
diff -u -d -r1.32 -r1.33
--- utils.h	2 Sep 2006 20:41:18 -0000	1.32
+++ utils.h	28 Jan 2007 21:46:41 -0000	1.33
@@ -80,8 +80,9 @@
 void usage (const char *) __attribute__((noreturn));
 void usage2(const char *, const char *) __attribute__((noreturn));
 void usage3(const char *, int) __attribute__((noreturn));
-void usage4(const char *);
-void usage_va(const char *fmt, ...);
+void usage4(const char *) __attribute__((noreturn));
+void usage5(void) __attribute__((noreturn));
+void usage_va(const char *fmt, ...) __attribute__((noreturn));
 
 const char *state_text (int);
 

Index: check_dig.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_dig.c,v
retrieving revision 1.45
retrieving revision 1.46
diff -u -d -r1.45 -r1.46
--- check_dig.c	19 Oct 2006 00:25:16 -0000	1.45
+++ check_dig.c	28 Jan 2007 21:46:40 -0000	1.46
@@ -265,8 +265,8 @@
     case 'a':
       expected_address = optarg;
       break;
-    default:                  /* usage_va */
-      usage_va(_("Unknown argument - %s"), optarg);
+    default:                  /* usage5 */
+      usage5();
     }
   }
 

Index: utils.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/utils.c,v
retrieving revision 1.50
retrieving revision 1.51
diff -u -d -r1.50 -r1.51
--- utils.c	13 Jul 2006 12:50:21 -0000	1.50
+++ utils.c	28 Jan 2007 21:46:41 -0000	1.51
@@ -94,6 +94,13 @@
 	exit (STATE_UNKNOWN);
 }
 
+void
+usage5 (void)
+{
+	print_usage();
+	exit (STATE_UNKNOWN);
+}
+
 char *
 clean_revstring (const char *revstring)
 {

Index: check_smtp.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_smtp.c,v
retrieving revision 1.55
retrieving revision 1.56
diff -u -d -r1.55 -r1.56
--- check_smtp.c	24 Jan 2007 22:47:24 -0000	1.55
+++ check_smtp.c	28 Jan 2007 21:46:40 -0000	1.56
@@ -664,7 +664,7 @@
 			print_help ();
 			exit (STATE_OK);
 		case '?':									/* help */
-			usage2 (_("Unknown argument"), optarg);
+			usage5 ();
 		}
 	}
 

Index: check_game.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_game.c,v
retrieving revision 1.28
retrieving revision 1.29
diff -u -d -r1.28 -r1.29
--- check_game.c	19 Oct 2006 00:25:16 -0000	1.28
+++ check_game.c	28 Jan 2007 21:46:40 -0000	1.29
@@ -249,7 +249,7 @@
         return ERROR;
       break;
     default: /* args not parsable */
-      usage_va(_("Unknown argument - %s"), optarg);
+      usage5();
     }
   }
 

Index: check_nagios.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_nagios.c,v
retrieving revision 1.31
retrieving revision 1.32
diff -u -d -r1.31 -r1.32
--- check_nagios.c	19 Oct 2006 00:25:16 -0000	1.31
+++ check_nagios.c	28 Jan 2007 21:46:40 -0000	1.32
@@ -258,7 +258,7 @@
 			verbose++;
 			break;
 		default:									/* print short usage_va statement if args not parsable */
-			usage_va(_("Unknown argument - %s"), optarg);
+			usage5();
 		}
 	}
 





More information about the Commits mailing list