diff --git a/snapper/BcachefsUtils.cc b/snapper/BcachefsUtils.cc index e9163ffb..1d328a78 100644 --- a/snapper/BcachefsUtils.cc +++ b/snapper/BcachefsUtils.cc @@ -24,6 +24,7 @@ #include #include +#include #include #include diff --git a/snapper/FileUtils.cc b/snapper/FileUtils.cc index d4034279..4c8578a1 100644 --- a/snapper/FileUtils.cc +++ b/snapper/FileUtils.cc @@ -387,9 +387,9 @@ namespace snapper std::pair SDir::statvfs() const { - struct statvfs64 fsbuf; - if (fstatvfs64(dirfd, &fsbuf) != 0) - SN_THROW(IOErrorException(sformat("statvfs64 failed path:%s errno:%d (%s)", base_path.c_str(), + struct statvfs fsbuf; + if (fstatvfs(dirfd, &fsbuf) != 0) + SN_THROW(IOErrorException(sformat("statvfs failed path:%s errno:%d (%s)", base_path.c_str(), errno, stringerror(errno).c_str()))); // f_bavail is used (not f_bfree) since df seems to do the