Follow "atomic" to "group" refactoring.
Remove noisy logging about UIDs that are relying on default cache
quota of 64MiB.
Move away from yucky old statfs() and use statvfs() instead.
Test: /data/nativetest/installd_cache_test/installd_cache_test
Bug: 35812899, 35684969, 36482620
Change-Id: I3d68da97eac2ebcda489bdf9d27061cac5b3f7cc
diff --git a/cmds/installd/CacheTracker.cpp b/cmds/installd/CacheTracker.cpp
index fada699..4bfc834 100644
--- a/cmds/installd/CacheTracker.cpp
+++ b/cmds/installd/CacheTracker.cpp
@@ -106,11 +106,11 @@
switch (p->fts_info) {
case FTS_D: {
auto item = static_cast<CacheItem*>(p->fts_pointer);
- item->atomic |= (getxattr(p->fts_path, kXattrCacheAtomic, nullptr, 0) >= 0);
+ item->group |= (getxattr(p->fts_path, kXattrCacheGroup, nullptr, 0) >= 0);
item->tombstone |= (getxattr(p->fts_path, kXattrCacheTombstone, nullptr, 0) >= 0);
- // When atomic, immediately collect all files under tree
- if (item->atomic) {
+ // When group, immediately collect all files under tree
+ if (item->group) {
while ((p = fts_read(fts)) != nullptr) {
if (p->fts_info == FTS_DP && p->fts_level == item->level) break;
switch (p->fts_info) {