From 71fcc19db98094c13b5217a32e390d3336560ace Mon Sep 17 00:00:00 2001 From: Karl DeBisschop Date: Fri, 1 Aug 2003 06:04:01 +0000 Subject: [PATCH] mark for transaltion git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@627 f882894a-f735-0410-b71e-b25c423dba1c --- plugins/check_dummy.c | 52 +++++++++++++++++++++++-------------------- 1 file changed, 28 insertions(+), 24 deletions(-) diff --git a/plugins/check_dummy.c b/plugins/check_dummy.c index ca37e98..c2f1f50 100644 --- a/plugins/check_dummy.c +++ b/plugins/check_dummy.c @@ -38,9 +38,31 @@ #include "utils.h" const char *progname = "check_dummy"; +const char *revision = "$Revision$"; +const char *copyright = "1999-2003"; +const char *email = "nagiosplug-devel@lists.sourceforge.net"; -void print_help (const char *); -void print_usage (const char *); +void +print_usage (void) +{ + printf (_("Usage: %s \n"), progname); +} + +void +print_help (void) +{ + print_revision (progname, revision); + + printf (_(COPYRIGHT), copyright, email); + + print_usage (); + + printf (_(HELP_VRSN)); + + printf (_("\n\ +This plugin will simply return the state corresponding to the numeric value\n\ +of the argument.\n")); +} int main (int argc, char **argv) @@ -48,19 +70,19 @@ main (int argc, char **argv) int result; if (argc != 2) { - printf ("Incorrect number of arguments supplied\n"); + printf (_("Incorrect number of arguments supplied\n")); exit (STATE_UNKNOWN); } else if (strcmp (argv[1], "-V") == 0 || strcmp (argv[1], "--version") == 0) { - print_revision (argv[0], "$Revision$"); + print_revision (progname, revision); exit (STATE_OK); } else if (strcmp (argv[1], "-h") == 0 || strcmp (argv[1], "--help") == 0) { - print_help (argv[0]); + print_help (); exit (STATE_OK); } else if (!is_integer (argv[1])) { - print_usage (argv[0]); + print_usage (); exit (STATE_UNKNOWN); } result = atoi (argv[1]); @@ -82,21 +104,3 @@ main (int argc, char **argv) return result; } - -void -print_help (const char *cmd) -{ - print_revision (cmd, "$Revision$"); - printf ("Copyright (c) 1999 Ethan Galstad (nagios@nagios.org)\n" - "License: GPL\n\n"); - print_usage (cmd); - printf - ("\nThis plugin will simply return the state corresponding to the numeric value\n" - "of the argument.\n"); -} - -void -print_usage (const char *cmd) -{ - printf ("Usage: %s \n", cmd); -} -- 2.30.2