diff options
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/check_disk.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/plugins/check_disk.c b/plugins/check_disk.c index 2f8afa6..f0950c9 100644 --- a/plugins/check_disk.c +++ b/plugins/check_disk.c | |||
@@ -118,9 +118,6 @@ enum | |||
118 | #pragma alloca | 118 | #pragma alloca |
119 | #endif | 119 | #endif |
120 | 120 | ||
121 | /* Linked list of mounted filesystems. */ | ||
122 | static struct mount_entry *mount_list; | ||
123 | |||
124 | int process_arguments (int, char **); | 121 | int process_arguments (int, char **); |
125 | void print_path (const char *mypath); | 122 | void print_path (const char *mypath); |
126 | void set_all_thresholds (struct parameter_list *path); | 123 | void set_all_thresholds (struct parameter_list *path); |
@@ -639,8 +636,12 @@ process_arguments (int argc, char **argv) | |||
639 | } | 636 | } |
640 | se->group = group; | 637 | se->group = group; |
641 | set_all_thresholds(se); | 638 | set_all_thresholds(se); |
642 | np_set_best_match(se, mount_list, exact_match); | 639 | |
640 | /* With autofs, it is required to stat() the path before populating the mount_list */ | ||
643 | stat_path(se); | 641 | stat_path(se); |
642 | mount_list = read_file_system_list (0); | ||
643 | np_set_best_match(se, mount_list, exact_match); | ||
644 | |||
644 | path_selected = TRUE; | 645 | path_selected = TRUE; |
645 | break; | 646 | break; |
646 | case 'x': /* exclude path or partition */ | 647 | case 'x': /* exclude path or partition */ |
@@ -757,7 +758,6 @@ process_arguments (int argc, char **argv) | |||
757 | case 'C': | 758 | case 'C': |
758 | /* add all mount entries to path_select list if no partitions have been explicitly defined using -p */ | 759 | /* add all mount entries to path_select list if no partitions have been explicitly defined using -p */ |
759 | if (path_selected == FALSE) { | 760 | if (path_selected == FALSE) { |
760 | struct mount_entry *me; | ||
761 | struct parameter_list *path; | 761 | struct parameter_list *path; |
762 | for (me = mount_list; me; me = me->me_next) { | 762 | for (me = mount_list; me; me = me->me_next) { |
763 | if (! (path = np_find_parameter(path_select_list, me->me_mountdir))) | 763 | if (! (path = np_find_parameter(path_select_list, me->me_mountdir))) |