diff --git a/bsp_q7s/core/CoreController.cpp b/bsp_q7s/core/CoreController.cpp index 85093fa3..9157c59b 100644 --- a/bsp_q7s/core/CoreController.cpp +++ b/bsp_q7s/core/CoreController.cpp @@ -1602,7 +1602,7 @@ void CoreController::performRebootWatchdogHandling(bool recreateFile) { std::string legacyPath = currMntPrefix + LEGACY_REBOOT_WATCHDOG_FILE; std::error_code e; // TODO: Remove at some point in the future. - if (std::filesystem::exists(legacyPath)) { + if (std::filesystem::exists(legacyPath, e)) { // Old file might still exist, so copy it to new path std::filesystem::copy(legacyPath, path, std::filesystem::copy_options::overwrite_existing, e); if (e) {