Browse Source

Fixed bug with malloc of wrong size

git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1358 f882894a-f735-0410-b71e-b25c423dba1c
Ton Voon 20 years ago
parent
commit
0f342875df
1 changed files with 1 additions and 1 deletions
  1. 1 1
      plugins/check_disk.c

+ 1 - 1
plugins/check_disk.c

@@ -554,7 +554,7 @@ process_arguments (int argc, char **argv)
 
   if (path_select_list) {
     temp_list = path_select_list;
-    stat_buf = malloc(sizeof stat_buf);
+    stat_buf = malloc(sizeof *stat_buf);
     while (temp_list) {
       /* Stat each entry to check that dir exists */
       if (stat (temp_list->name, &stat_buf[0])) {