Skip to content

Commit

Permalink
Merge pull request #49222 from bruvzg/fix_unix_free_space
Browse files Browse the repository at this point in the history
Fix `Directory::get_space_left()` result on macOS and Linux.
  • Loading branch information
akien-mga authored May 31, 2021
2 parents 4a97424 + 1d7a63f commit afe776c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/unix/dir_access_unix.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -460,7 +460,7 @@ uint64_t DirAccessUnix::get_space_left() {
return 0;
};

return vfs.f_bfree * vfs.f_bsize;
return (uint64_t)vfs.f_bavail * (uint64_t)vfs.f_frsize;
#else
// FIXME: Implement this.
return 0;
Expand Down

0 comments on commit afe776c

Please sign in to comment.