From 48083201214fe6d70829d4fb410a493a07fb2512 Mon Sep 17 00:00:00 2001 From: Maschell Date: Sat, 25 Dec 2021 23:58:54 +0100 Subject: [PATCH] OSFatal on error --- source/main.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/source/main.cpp b/source/main.cpp index ab1bdb0..d23f849 100644 --- a/source/main.cpp +++ b/source/main.cpp @@ -16,6 +16,7 @@ #include #include #include +#include #include "utils/StringTools.h" #include "fs/DirList.h" @@ -101,7 +102,9 @@ int main(int argc, char **argv) { DEBUG_FUNCTION_LINE("Loaded module data"); auto relocData = moduleData.value()->getRelocationDataList(); if (!ElfUtils::doRelocation(relocData, gModuleData->trampolines, DYN_LINK_TRAMPOLIN_LIST_LENGTH)) { - DEBUG_FUNCTION_LINE("relocations failed\n"); + OSFatal("Relocations failed"); + } else { + DEBUG_FUNCTION_LINE("Relocation done"); } DEBUG_FUNCTION_LINE("Calling entrypoint @%08X", moduleData.value()->getEntrypoint());