fixed free space detection on some systems

This commit is contained in:
Martinez 2015-02-26 15:38:13 +01:00
parent 1f18d2a5e0
commit 933235a840

View file

@ -346,7 +346,7 @@ void get_available_space(std::vector<Space> &space) {
// figure out free and total space // figure out free and total space
statfs(mountpoint.c_str(), &stats); statfs(mountpoint.c_str(), &stats);
free_space = stats.f_bavail * stats.f_bsize; free_space = stats.f_bfree * stats.f_bsize;
total_space = stats.f_blocks * stats.f_bsize; total_space = stats.f_blocks * stats.f_bsize;
// pass it on // pass it on