Skip to content

Commit 6a74818

Browse files
authored
Merge pull request #945 from kraj/kraj/musl
Fixes for building on musl systems
2 parents 64efd34 + 0b39f44 commit 6a74818

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

snapper/BcachefsUtils.cc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@
2424

2525
#include <cstring>
2626
#include <cerrno>
27+
#include <linux/types.h>
2728
#include <sys/stat.h>
2829
#include <sys/ioctl.h>
2930

snapper/FileUtils.cc

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -387,9 +387,9 @@ namespace snapper
387387
std::pair<unsigned long long, unsigned long long>
388388
SDir::statvfs() const
389389
{
390-
struct statvfs64 fsbuf;
391-
if (fstatvfs64(dirfd, &fsbuf) != 0)
392-
SN_THROW(IOErrorException(sformat("statvfs64 failed path:%s errno:%d (%s)", base_path.c_str(),
390+
struct statvfs fsbuf;
391+
if (fstatvfs(dirfd, &fsbuf) != 0)
392+
SN_THROW(IOErrorException(sformat("statvfs failed path:%s errno:%d (%s)", base_path.c_str(),
393393
errno, stringerror(errno).c_str())));
394394

395395
// f_bavail is used (not f_bfree) since df seems to do the

0 commit comments

Comments
 (0)