Skip to content

Commit

Permalink
Enabled logs for free disk space checks when downloading/updating cou…
Browse files Browse the repository at this point in the history
…ntries

There are several bug reports that iOS wrongly says that there is no free space available.
As we can get iOS logs now, we can try to debug such cases.

Signed-off-by: Alexander Borsuk <me@alex.bio>
  • Loading branch information
biodranik committed Aug 14, 2024
1 parent a86c911 commit 156cc95
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions platform/platform_unix_impl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ Platform::TStorageStatus Platform::GetWritableStorageStatus(uint64_t neededSize)
struct statfs st;
int const ret = statfs(m_writableDir.c_str(), &st);

LOG(LDEBUG, ("statfs return =", ret,
LOG(LINFO, ("statfs return =", ret,
"; block size =", st.f_bsize,
"; blocks available =", st.f_bavail));

Expand All @@ -125,7 +125,7 @@ Platform::TStorageStatus Platform::GetWritableStorageStatus(uint64_t neededSize)
}

auto const availableBytes = st.f_bsize * st.f_bavail;
LOG(LDEBUG, ("Free space check: requested =", neededSize, "; available =", availableBytes));
LOG(LINFO, ("Free space check: requested =", neededSize, "; available =", availableBytes));
if (availableBytes < neededSize)
return NOT_ENOUGH_SPACE;

Expand Down

0 comments on commit 156cc95

Please sign in to comment.