]> git.sur5r.net Git - bacula/bacula/blobdiff - bacula/src/lib/bsys.c
Restore win32 dir from Branch-5.2 and update it
[bacula/bacula] / bacula / src / lib / bsys.c
index 916357493b21ca7517c9c8caf7b116a4621af3a5..4a4569ad53d316a9ef922e428f29c4a926e03c35 100644 (file)
@@ -1029,15 +1029,7 @@ void stack_trace() {}
 
 int fs_get_free_space(const char *path, int64_t *freeval, int64_t *totalval)
 {
-
-/* For Windows must have statvfs */
-#if defined(HAVE_WIN32)
-   #if !defined(HAVE_SYS_STATVFS_H)
-      *totalval = *freeval = 0;
-      return -1;
-   #endif
-#endif
-
+#ifndef HAVE_WIN32
    struct statvfs st;
 
    if (statvfs(path, &st) == 0) {
@@ -1045,6 +1037,7 @@ int fs_get_free_space(const char *path, int64_t *freeval, int64_t *totalval)
       *totalval = (uint64_t)st.f_blocks * (uint64_t)st.f_frsize;
       return 0;
    }
+#endif
 
    *totalval = *freeval = 0;
    return -1;