mirror of
https://github.com/nextcloud/desktop.git
synced 2024-11-27 09:30:13 +03:00
FreeBSD doesn't have statvfs64, like MacOS X.
This commit is contained in:
parent
2b652422b9
commit
1c594b6a8d
1 changed files with 1 additions and 1 deletions
|
@ -163,7 +163,7 @@ void Utility::setLaunchOnStartup(const QString &appName, const QString& guiName,
|
||||||
|
|
||||||
qint64 Utility::freeDiskSpace(const QString &path, bool *ok)
|
qint64 Utility::freeDiskSpace(const QString &path, bool *ok)
|
||||||
{
|
{
|
||||||
#ifdef Q_OS_MAC
|
#if defined(Q_OS_MAC) || defined(Q_OS_FREEBSD)
|
||||||
struct statvfs stat;
|
struct statvfs stat;
|
||||||
statvfs(path.toUtf8().data(), &stat);
|
statvfs(path.toUtf8().data(), &stat);
|
||||||
return (qint64) stat.f_bavail * stat.f_frsize;
|
return (qint64) stat.f_bavail * stat.f_frsize;
|
||||||
|
|
Loading…
Reference in a new issue