diff --git a/Crashlytics/CHANGELOG.md b/Crashlytics/CHANGELOG.md index 997798c64db..7fa1e2c85b6 100644 --- a/Crashlytics/CHANGELOG.md +++ b/Crashlytics/CHANGELOG.md @@ -1,3 +1,6 @@ +# Unreleased +- [changed] Removed calls to statfs in the Crashlytics SDK to comply with Apple Privacy Manifests. This change removes support for showing Disk Space Free in the Crashlytics console. + # 10.16.0 - [fixed] Fixed a memory leak regression when generating session events (#11725). diff --git a/Crashlytics/Crashlytics/Components/FIRCLSHost.m b/Crashlytics/Crashlytics/Components/FIRCLSHost.m index f4b117c4eac..c1f41a0182b 100644 --- a/Crashlytics/Crashlytics/Components/FIRCLSHost.m +++ b/Crashlytics/Crashlytics/Components/FIRCLSHost.m @@ -15,7 +15,6 @@ #include "Crashlytics/Crashlytics/Components/FIRCLSHost.h" #include -#include #include #import "Crashlytics/Crashlytics/Components/FIRCLSApplication.h" @@ -180,16 +179,15 @@ bool FIRCLSHostRecord(FIRCLSFile* file) { } void FIRCLSHostWriteDiskUsage(FIRCLSFile* file) { - struct statfs tStats; - FIRCLSFileWriteSectionStart(file, "storage"); FIRCLSFileWriteHashStart(file); - if (statfs(_firclsContext.readonly->host.documentDirectoryPath, &tStats) == 0) { - FIRCLSFileWriteHashEntryUint64(file, "free", tStats.f_bavail * tStats.f_bsize); - FIRCLSFileWriteHashEntryUint64(file, "total", tStats.f_blocks * tStats.f_bsize); - } + // Due to Apple Privacy Manifests, Crashlytics is not collecting + // disk space using statfs. When we find a solution, we can update + // this to actually track disk space correctly. + FIRCLSFileWriteHashEntryUint64(file, "free", 0); + FIRCLSFileWriteHashEntryUint64(file, "total", 0); FIRCLSFileWriteHashEnd(file);