fix(fs): Use available bytes to calculate free disk space

Refs #396
This commit is contained in:
Michael Carlberg 2017-01-30 14:39:05 +01:00
parent 9f1d9a14fd
commit 82d360e634

View File

@ -165,7 +165,7 @@ namespace modules {
m_labelmounted->replace_token( m_labelmounted->replace_token(
"%total%", string_util::filesize(mount->bytes_total, m_fixed ? 2 : 0, m_fixed, m_bar.locale)); "%total%", string_util::filesize(mount->bytes_total, m_fixed ? 2 : 0, m_fixed, m_bar.locale));
m_labelmounted->replace_token( m_labelmounted->replace_token(
"%free%", string_util::filesize(mount->bytes_free, m_fixed ? 2 : 0, m_fixed, m_bar.locale)); "%free%", string_util::filesize(mount->bytes_avail, m_fixed ? 2 : 0, m_fixed, m_bar.locale));
m_labelmounted->replace_token( m_labelmounted->replace_token(
"%used%", string_util::filesize(mount->bytes_used, m_fixed ? 2 : 0, m_fixed, m_bar.locale)); "%used%", string_util::filesize(mount->bytes_used, m_fixed ? 2 : 0, m_fixed, m_bar.locale));
builder->node(m_labelmounted); builder->node(m_labelmounted);