diff --git a/src/activities/boot_sleep/SleepActivity.cpp b/src/activities/boot_sleep/SleepActivity.cpp index 93622a03..1b59719b 100644 --- a/src/activities/boot_sleep/SleepActivity.cpp +++ b/src/activities/boot_sleep/SleepActivity.cpp @@ -155,7 +155,10 @@ std::string SleepActivity::getBookOverlayText(const std::string& bookPath) const if (Storage.openFileForRead("SLP", xtc.getCachePath() + "/progress.bin", f)) { uint8_t data[4]; if (f.read(data, 4) == 4) { - uint32_t currentPage = data[0] | (data[1] << 8) | (data[2] << 16) | (data[3] << 24); + uint32_t currentPage = static_cast(data[0]) | + (static_cast(data[1]) << 8) | + (static_cast(data[2]) << 16) | + (static_cast(data[3]) << 24); uint32_t totalPages = xtc.getPageCount(); float progress = xtc.calculateProgress(currentPage) * 100.0f; char progressStr[32];