summaryrefslogtreecommitdiffstats
path: root/plugins/check_disk.c
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/check_disk.c')
-rw-r--r--plugins/check_disk.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/plugins/check_disk.c b/plugins/check_disk.c
index 7974d141..c8cfecd2 100644
--- a/plugins/check_disk.c
+++ b/plugins/check_disk.c
@@ -237,8 +237,8 @@ process_arguments (int argc, char **argv)
237 237
238 unsigned long l; 238 unsigned long l;
239 239
240 int option_index = 0; 240 int option = 0;
241 static struct option long_options[] = { 241 static struct option longopts[] = {
242 {"timeout", required_argument, 0, 't'}, 242 {"timeout", required_argument, 0, 't'},
243 {"warning", required_argument, 0, 'w'}, 243 {"warning", required_argument, 0, 'w'},
244 {"critical", required_argument, 0, 'c'}, 244 {"critical", required_argument, 0, 'c'},
@@ -274,7 +274,7 @@ process_arguments (int argc, char **argv)
274 strcpy (argv[c], "-t"); 274 strcpy (argv[c], "-t");
275 275
276 while (1) { 276 while (1) {
277 c = getopt_long (argc, argv, "+?VqhveCt:c:w:u:p:x:X:mklM", long_options, &option_index); 277 c = getopt_long (argc, argv, "+?VqhveCt:c:w:u:p:x:X:mklM", longopts, &option);
278 278
279 if (c == -1 || c == EOF) 279 if (c == -1 || c == EOF)
280 break; 280 break;
@@ -363,7 +363,7 @@ process_arguments (int argc, char **argv)
363 break; 363 break;
364 case 'p': /* select path */ 364 case 'p': /* select path */
365 se = (struct name_list *) malloc (sizeof (struct name_list)); 365 se = (struct name_list *) malloc (sizeof (struct name_list));
366 se->name = strdup (optarg); 366 se->name = optarg;
367 se->name_next = NULL; 367 se->name_next = NULL;
368 se->w_df = w_df; 368 se->w_df = w_df;
369 se->c_df = c_df; 369 se->c_df = c_df;
@@ -374,14 +374,14 @@ process_arguments (int argc, char **argv)
374 break; 374 break;
375 case 'x': /* exclude path or partition */ 375 case 'x': /* exclude path or partition */
376 se = (struct name_list *) malloc (sizeof (struct name_list)); 376 se = (struct name_list *) malloc (sizeof (struct name_list));
377 se->name = strdup (optarg); 377 se->name = optarg;
378 se->name_next = NULL; 378 se->name_next = NULL;
379 *dptail = se; 379 *dptail = se;
380 dptail = &se->name_next; 380 dptail = &se->name_next;
381 break; 381 break;
382 case 'X': /* exclude file system type */ 382 case 'X': /* exclude file system type */
383 se = (struct name_list *) malloc (sizeof (struct name_list)); 383 se = (struct name_list *) malloc (sizeof (struct name_list));
384 se->name = strdup (optarg); 384 se->name = optarg;
385 se->name_next = NULL; 385 se->name_next = NULL;
386 *fstail = se; 386 *fstail = se;
387 fstail = &se->name_next; 387 fstail = &se->name_next;