Skip to content
Commit 72378425 authored by Michael Pyne's avatar Michael Pyne
Browse files

Try to ensure disk cache is fully on-disk.

KSharedDataCache will use posix_fallocate() if it is available to try to
ensure that the file used for the disk cache is actually fully committed
to disk before using it. This should hopefully avoid crashes due to lack
of disk space.

Not all filesystems support posix_fallocate. If that function is not
claimed to be supported at compile time then a warning is issued, but
there are no other functionality changes. If the system claims to
support posix_fallocate and still fails, then it is assumed there is
really no space and KSharedDataCache will fallback to private memory.

This corresponds to KDE Platform 4.7. I intend to backport, but somehow
4.6 and 4.7 are already different enough that the patch wouldn't have
been a mere merge or cherry-pick, so perhaps in a few days once people
other than myself have had time to test.

CCBUG:245173
parent df8d6e15
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment