mirror of
https://github.com/HASwitchPlate/openHASP.git
synced 2025-07-24 11:46:34 +00:00
Merge pull request #737 from FreeBear-nc/bugfixes
Missing the FILE_SIZE_DIVIDER for gigabits
This commit is contained in:
commit
9254fac675
@ -212,6 +212,7 @@ int Parser::format_bytes(size_t filesize, char* buf, size_t len)
|
||||
return snprintf_P(buf, len, PSTR("%d" D_DECIMAL_POINT "%02d " D_FILE_SIZE_MEGABYTES), filesize / 100,
|
||||
filesize % 100);
|
||||
|
||||
filesize = filesize / D_FILE_SIZE_DIVIDER; // multiply by 100 for 2 decimal place
|
||||
return snprintf_P(buf, len, PSTR("%d" D_DECIMAL_POINT "%02d " D_FILE_SIZE_GIGABYTES), filesize / 100,
|
||||
filesize % 100);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user