diff options
author | Benoit Mortier <opensides@users.sourceforge.net> | 2004-12-03 00:55:28 +0000 |
---|---|---|
committer | Benoit Mortier <opensides@users.sourceforge.net> | 2004-12-03 00:55:28 +0000 |
commit | 016d33230eb4fffd7e1f5644ce4901cb4d01f4e3 (patch) | |
tree | 1a6f29dcfd937bccffb66467127613b660d55365 /plugins/check_mrtg.c | |
parent | 3f05eb7fcb71942c90fa7d5796c3d18ed62443cf (diff) | |
download | monitoring-plugins-016d33230eb4fffd7e1f5644ce4901cb4d01f4e3.tar.gz |
bump copyright year
initialize result to STATE_UNKNOW in place of STATE_OK
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@982 f882894a-f735-0410-b71e-b25c423dba1c
Diffstat (limited to 'plugins/check_mrtg.c')
-rw-r--r-- | plugins/check_mrtg.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/plugins/check_mrtg.c b/plugins/check_mrtg.c index 31d132d4..7cf7d897 100644 --- a/plugins/check_mrtg.c +++ b/plugins/check_mrtg.c | |||
@@ -20,7 +20,7 @@ | |||
20 | 20 | ||
21 | const char *progname = "check_mrtg"; | 21 | const char *progname = "check_mrtg"; |
22 | const char *revision = "$Revision$"; | 22 | const char *revision = "$Revision$"; |
23 | const char *copyright = "1999-2001"; | 23 | const char *copyright = "1999-2004"; |
24 | const char *email = "nagiosplug-devel@lists.sourceforge.net"; | 24 | const char *email = "nagiosplug-devel@lists.sourceforge.net"; |
25 | 25 | ||
26 | #include "common.h" | 26 | #include "common.h" |
@@ -43,7 +43,7 @@ char *units; | |||
43 | int | 43 | int |
44 | main (int argc, char **argv) | 44 | main (int argc, char **argv) |
45 | { | 45 | { |
46 | int result = STATE_OK; | 46 | int result = STATE_UNKNOWN; |
47 | FILE *fp; | 47 | FILE *fp; |
48 | int line; | 48 | int line; |
49 | char input_buffer[MAX_INPUT_BUFFER]; | 49 | char input_buffer[MAX_INPUT_BUFFER]; |
@@ -152,7 +152,9 @@ main (int argc, char **argv) | |||
152 | 152 | ||
153 | return result; | 153 | return result; |
154 | } | 154 | } |
155 | 155 | ||
156 | |||
157 | |||
156 | /* process command-line arguments */ | 158 | /* process command-line arguments */ |
157 | int | 159 | int |
158 | process_arguments (int argc, char **argv) | 160 | process_arguments (int argc, char **argv) |
@@ -210,7 +212,7 @@ process_arguments (int argc, char **argv) | |||
210 | case 'v': | 212 | case 'v': |
211 | variable_number = atoi (optarg); | 213 | variable_number = atoi (optarg); |
212 | if (variable_number < 1 || variable_number > 2) | 214 | if (variable_number < 1 || variable_number > 2) |
213 | usage (_("Invalid variable number\n")); | 215 | usage4 (_("Invalid variable number")); |
214 | break; | 216 | break; |
215 | case 'w': /* critical time threshold */ | 217 | case 'w': /* critical time threshold */ |
216 | value_warning_threshold = strtoul (optarg, NULL, 10); | 218 | value_warning_threshold = strtoul (optarg, NULL, 10); |
@@ -291,7 +293,7 @@ int | |||
291 | validate_arguments (void) | 293 | validate_arguments (void) |
292 | { | 294 | { |
293 | if (variable_number == -1) | 295 | if (variable_number == -1) |
294 | usage (_("You must supply the variable number\n")); | 296 | usage4 (_("You must supply the variable number")); |
295 | 297 | ||
296 | if (label == NULL) | 298 | if (label == NULL) |
297 | label = strdup ("value"); | 299 | label = strdup ("value"); |