From b531cfa38eb3cd254a70f77740ea410fee8a72d0 Mon Sep 17 00:00:00 2001 From: Tulio Leao Date: Sun, 25 Feb 2024 17:28:48 -0300 Subject: [PATCH] Do not try patch if scenarioPath is empty --- src/openrct2/rct12/ScenarioPatcher.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/openrct2/rct12/ScenarioPatcher.cpp b/src/openrct2/rct12/ScenarioPatcher.cpp index 41a4eda3f8..3e2b7ae80a 100644 --- a/src/openrct2/rct12/ScenarioPatcher.cpp +++ b/src/openrct2/rct12/ScenarioPatcher.cpp @@ -466,6 +466,11 @@ void RCT12::ApplyScenarioPatch(u8string_view scenarioPatchFile, u8string scenari void RCT12::FetchAndApplyScenarioPatch(u8string_view scenarioPath, bool isScenario) { + if (scenarioPath.empty()) + { + return; + } + auto scenarioSHA = getScenarioSHA256(scenarioPath); auto patchPath = GetPatchFileName(scenarioSHA); std::cout << "Patch is: " << patchPath << " full SHA" << scenarioSHA << std::endl;