From 54c21eba62b55503dbe6fda607ccbef4a27a1f14 Mon Sep 17 00:00:00 2001
From: Benoit Mortier <opensides@users.sourceforge.net>
Date: Wed, 1 Dec 2004 19:33:45 +0000
Subject: first pass at standardization of messages for the localization

git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@962 f882894a-f735-0410-b71e-b25c423dba1c

diff --git a/plugins/check_by_ssh.c b/plugins/check_by_ssh.c
index 9500cb3..6daa1a1 100644
--- a/plugins/check_by_ssh.c
+++ b/plugins/check_by_ssh.c
@@ -167,11 +167,6 @@ main (int argc, char **argv)
 	return result;
 }
 
-
-
-
-
-
 /* process command-line arguments */
 int
 process_arguments (int argc, char **argv)
@@ -238,12 +233,12 @@ process_arguments (int argc, char **argv)
 			break;
 		case 'H':									/* host */
 			if (!is_host (optarg))
-				usage2 (_("Invalid host name"), optarg);
+				usage2 (_("Invalid hostname/adress"), optarg);
 			hostname = optarg;
 			break;
 		case 'p': /* port number */
 			if (!is_integer (optarg))
-				usage2 (_("port must be an integer"), optarg);
+				usage2 (_("port must be a positive integer"), optarg);
 			asprintf (&comm,"%s -p %s", comm, optarg);
 			break;
 		case 'O':									/* output file */
@@ -340,10 +335,6 @@ validate_arguments (void)
 }
 
 
-
-
-
-
 void
 print_help (void)
 {
diff --git a/plugins/check_dig.c b/plugins/check_dig.c
index 92a5eda..5b472ec 100644
--- a/plugins/check_dig.c
+++ b/plugins/check_dig.c
@@ -151,7 +151,7 @@ main (int argc, char **argv)
 	if (spclose (child_process)) {
 		result = max_state (result, STATE_WARNING);
 		if (strlen (output) == 0)
-			asprintf (&output, _("dig returned error status"));
+			asprintf (&output, _("dig returned an error status"));
 	}
 
 	microsec = deltime (tv);
@@ -183,7 +183,6 @@ main (int argc, char **argv)
 
 
 
-
 /* process command-line arguments */
 int
 process_arguments (int argc, char **argv)
@@ -228,7 +227,7 @@ process_arguments (int argc, char **argv)
 				dns_server = optarg;
 			}
 			else {
-				usage2 (_("Invalid host name"), optarg);
+				usage2 (_("Invalid hostname/adress"), optarg);
 			}
 			break;
 		case 'p':                 /* server port */
@@ -236,7 +235,7 @@ process_arguments (int argc, char **argv)
 				server_port = atoi (optarg);
 			}
 			else {
-				usage2 (_("Server port must be a nonnegative integer"), optarg);
+				usage2 (_("port must be a positive integer"), optarg);
 			}
 			break;
 		case 'l':									/* address to lookup */
@@ -247,7 +246,7 @@ process_arguments (int argc, char **argv)
 				warning_interval = strtod (optarg, NULL);
 			}
 			else {
-				usage2 (_("Warning interval must be a nonnegative integer"), optarg);
+				usage2 (_("Warning interval must be a positive integer"), optarg);
 			}
 			break;
 		case 'c':									/* critical */
@@ -255,7 +254,7 @@ process_arguments (int argc, char **argv)
 				critical_interval = strtod (optarg, NULL);
 			}
 			else {
-				usage2 (_("Critical interval must be a nonnegative integer"), optarg);
+				usage2 (_("Critical interval must be a positive integer"), optarg);
 			}
 			break;
 		case 't':									/* timeout */
@@ -263,7 +262,7 @@ process_arguments (int argc, char **argv)
 				timeout_interval = atoi (optarg);
 			}
 			else {
-				usage2 (_("Time interval must be a nonnegative integer"), optarg);
+				usage2 (_("Timeout interval must be a positive integer"), optarg);
 			}
 			break;
 		case 'v':									/* verbose */
@@ -285,7 +284,7 @@ process_arguments (int argc, char **argv)
 				dns_server = argv[c];
 			}
 			else {
-				usage2 (_("Invalid host name"), argv[c]);
+				usage2 (_("Invalid hostname/adress"), argv[c]);
 			}
 		}
 		else {
@@ -311,7 +310,6 @@ validate_arguments (void)
 
 
 
-
 void
 print_help (void)
 {
diff --git a/plugins/check_disk.c b/plugins/check_disk.c
index 95e8475..c823925 100644
--- a/plugins/check_disk.c
+++ b/plugins/check_disk.c
@@ -437,7 +437,7 @@ process_arguments (int argc, char **argv)
 			print_help ();
 			exit (STATE_OK);
 		case '?':									/* help */
-			usage (_("check_disk: unrecognized option\n"));
+			usage (_("Unknow argument\n"));
 			break;
 		}
 	}
@@ -566,7 +566,6 @@ walk_name_list (struct name_list *list, const char *name)
 
 
 
-
 void
 print_help (void)
 {
diff --git a/plugins/check_dns.c b/plugins/check_dns.c
index 7b18270..6c08c27 100644
--- a/plugins/check_dns.c
+++ b/plugins/check_dns.c
@@ -207,7 +207,7 @@ main (int argc, char **argv)
 		printf (_("DNS CRITICAL - %s\n"),
 		        !strcmp (output, "") ? _(" Probably a non-existent host/domain") : output);
 	else
-		printf (_("DNS problem - %s\n"),
+		printf (_("DNS UNKNOW - %s\n"),
 		        !strcmp (output, "") ? _(" Probably a non-existent host/domain") : output);
 
 	return result;
@@ -331,7 +331,7 @@ process_arguments (int argc, char **argv)
 		case 'r': /* reverse server name */
 			/* TODO: Is this is_host necessary? */
 			if (is_host (optarg) == FALSE) {
-				usage2 (_("Invalid host name/address"), optarg);
+				usage2 (_("Invalid hostname/address"), optarg);
 			}
 			if (strlen (optarg) >= ADDRESS_LENGTH)
 				die (STATE_UNKNOWN, _("Input buffer overflow\n"));
@@ -359,7 +359,7 @@ process_arguments (int argc, char **argv)
 	if (strlen(dns_server)==0 && c<argc) {
 		/* TODO: See -s option */
 		if (is_host(argv[c]) == FALSE) {
-			printf (_("Invalid name/address: %s\n\n"), argv[c]);
+			printf (_("Invalid hostname/address: %s\n\n"), argv[c]);
 			return ERROR;
 		}
 		if (strlen(argv[c]) >= ADDRESS_LENGTH)
diff --git a/plugins/check_fping.c b/plugins/check_fping.c
index 22f6b55..2dba2d5 100644
--- a/plugins/check_fping.c
+++ b/plugins/check_fping.c
@@ -127,16 +127,16 @@ textscan (char *buf)
 	int status = STATE_UNKNOWN;
 
 	if (strstr (buf, "not found")) {
-		die (STATE_CRITICAL, _("FPING unknown - %s not found\n"), server_name);
+		die (STATE_CRITICAL, _("FPING UNKNOW - %s not found\n"), server_name);
 
 	}
 	else if (strstr (buf, "is unreachable") || strstr (buf, "Unreachable")) {
-		die (STATE_CRITICAL, _("FPING critical - %s is unreachable\n"),
+		die (STATE_CRITICAL, _("FPING CRITICAL - %s is unreachable\n"),
 							 "host");
 
 	}
 	else if (strstr (buf, "is down")) {
-		die (STATE_CRITICAL, _("FPING critical - %s is down\n"), server_name);
+		die (STATE_CRITICAL, _("FPING CRITICAL - %s is down\n"), server_name);
 
 	}
 	else if (strstr (buf, "is alive")) {
@@ -254,7 +254,7 @@ process_arguments (int argc, char **argv)
 			break;
 		case 'H':									/* hostname */
 			if (is_host (optarg) == FALSE) {
-				usage2 (_("Invalid host name/address"), optarg);
+				usage2 (_("Invalid hostname/address"), optarg);
 			}
 			server_name = strscpy (server_name, optarg);
 			break;
@@ -301,7 +301,7 @@ process_arguments (int argc, char **argv)
 
 
 	if (server_name == NULL)
-		usage (_("Host name was not supplied\n\n"));
+		usage (_("Hostname was not supplied\n\n"));
 
 	return OK;
 }
diff --git a/plugins/check_ssh.c b/plugins/check_ssh.c
index 86267b2..ea74fa8 100644
--- a/plugins/check_ssh.c
+++ b/plugins/check_ssh.c
@@ -104,7 +104,8 @@ process_arguments (int argc, char **argv)
 
 		switch (c) {
 		case '?':									/* help */
-			usage ("");
+			usage (_("Unknow argument\n"));
+			break;
 		case 'V':									/* version */
 			print_revision (progname, revision);
 			exit (STATE_OK);
@@ -135,7 +136,7 @@ process_arguments (int argc, char **argv)
 			break;
 		case 'H':									/* host */
 			if (is_host (optarg) == FALSE)
-				usage2 (_("Invalid host name/address"), optarg);
+				usage2 (_("Invalid hostname/address"), optarg);
 			server_name = optarg;
 			break;
 		case 'p':									/* port */
@@ -250,7 +251,7 @@ print_help (void)
 	printf ("Copyright (c) 1999 Remi Paulmier <remi@sinfomic.fr>\n");
 	printf (COPYRIGHT, copyright, email);
 
-	printf (_("Try to connect to SSH server at specified server and port\n\n"));
+	printf (_("Try to connect to an SSH server at specified server and port\n\n"));
 
 	print_usage ();
 
-- 
cgit v0.10-9-g596f

