Skip to content

Resolve "filesystem::{free,size,used} not set for full FAT fs"

Philip Withnall requested to merge pwithnall/glib:328-file-system-full into master

Previously, glocalfile.c would not set file system metadata for the free/used key for file systems which reported 0 free space. This is because some file systems don’t set that metadata when you call statfs(), so we can’t reliably report it. However, some do, and they can legitimately set f_bavail and f_bfree to 0 if the file system is full.

In order to avoid that, always set the file system metadata unless the file system is FUSE or ncpfs.

Signed-off-by: Philip Withnall withnall@endlessm.com

#328 (closed)

Closes #328 (closed)

Merge request reports