[Nagiosplug-checkins] CVS: nagiosplug/plugins check_disk.c,1.26,1.27

Ton Voon tonvoon at users.sourceforge.net
Mon Jun 30 10:03:09 CEST 2003


Update of /cvsroot/nagiosplug/nagiosplug/plugins
In directory sc8-pr-cvs1:/tmp/cvs-serv31919

Modified Files:
	check_disk.c 
Log Message:
Fixed support for "check_disk warn crit [path]" with thresholds at used levels


Index: check_disk.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_disk.c,v
retrieving revision 1.26
retrieving revision 1.27
diff -C2 -r1.26 -r1.27
*** check_disk.c	26 Jun 2003 23:33:49 -0000	1.26
--- check_disk.c	30 Jun 2003 17:02:19 -0000	1.27
***************
*** 427,431 ****
  			dptail = &se->name_next;
  			break;
-  			break;
  		case 'X':									/* exclude file system type */
  			se = (struct name_list *) malloc (sizeof (struct name_list));
--- 427,430 ----
***************
*** 465,468 ****
--- 464,468 ----
  	}
  
+ 	/* Support for "check_disk warn crit [fs]" with thresholds at used level */
  	c = optind;
  	if (w_dfp == -1 && argc > c && is_intnonneg (argv[c]))
***************
*** 472,477 ****
  		c_dfp = (100.0 - atof (argv[c++]));
  
! 	if (argc > c && strlen (path) == 0)
! 		path = argv[c++];
  
  	if (path_select_list) {
--- 472,485 ----
  		c_dfp = (100.0 - atof (argv[c++]));
  
! 	if (argc > c && strlen (path) == 0) {
! 		se = (struct name_list *) malloc (sizeof (struct name_list));
! 		se->name = strdup (argv[c++]);
! 		se->name_next = NULL;
! 		se->w_df = w_df;
! 		se->c_df = c_df;
! 		se->w_dfp = w_dfp;
! 		se->c_dfp = c_dfp;
! 		*pathtail = se;
! 	}
  
  	if (path_select_list) {





More information about the Commits mailing list