diff --git a/plugins/check_ups.c b/plugins/check_ups.c
index 4006031f183f3ddd98f94da01935f5527a50bef6..a4d765038882a9493767af05a96113ec8ff7b0fb 100644 (file)
--- a/plugins/check_ups.c
+++ b/plugins/check_ups.c
const char *progname = "check_ups";
const char *revision = "$Revision$";
-const char *copyright = "2000-2002";
+const char *copyright = "2000-2004";
const char *email = "nagiosplug-devel@lists.sourceforge.net";
-#include <locale.h>
#include "common.h"
#include "netutils.h"
#include "utils.h"
int
main (int argc, char **argv)
{
- int result = STATE_OK;
+ int result = STATE_UNKNOWN;
char *message;
char *data;
char temp_buffer[MAX_INPUT_BUFFER];
data = strdup ("");
message = strdup ("");
- if (process_arguments (argc, argv) != TRUE)
- usage (_("check_ups: could not parse arguments\n"));
+ if (process_arguments (argc, argv) == ERROR)
+ usage4 (_("Could not parse arguments"));
/* initialize alarm signal handling */
signal (SIGALRM, socket_timeout_alarm_handler);
printf ("Copyright (c) 2000 Tom Shields");
printf ("Copyright (c) 2004 Alain Richard <alain.richard@equation.fr>\n");
printf ("Copyright (c) 2004 Arnaud Quette <arnaud.quette@mgeups.com>\n");
-
printf (COPYRIGHT, copyright, email);
printf (_("This plugin tests the UPS service on the specified host.\n\
void
print_usage (void)
{
- printf (_("\
+ printf ("\
Usage: %s -H host -u ups [-p port] [-v variable]\n\
- [-wv warn_value] [-cv crit_value] [-to to_sec] [-T]\n"), progname);
- printf (_(UT_HLP_VRS), progname, progname);
+ [-wv warn_value] [-cv crit_value] [-to to_sec] [-T]\n", progname);
}