Skip to content

Commit

Permalink
fix: also debug failed scan on windows
Browse files Browse the repository at this point in the history
it *is* handy for debugging probably
  • Loading branch information
ThisAMJ committed Sep 22, 2024
1 parent 055f492 commit 38048b2
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/Utils/Memory.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -150,8 +150,10 @@ uintptr_t Memory::Scan(const char *moduleName, const char *pattern, int offset)
if (result == 0) {
if (console) console->DevMsg("Failed to find pattern \"%s\" in module \"%s\"\n", pattern, moduleName);
#ifdef SAR_DEV_BUILD
#ifndef _WIN32
// handy for debugging
#ifdef _WIN32
RaiseException(STATUS_ASSERTION_FAILURE, EXCEPTION_CONTINUE_EXECUTION, 0, nullptr);
#else
raise(SIGTRAP);
#endif
#endif
Expand Down

0 comments on commit 38048b2

Please sign in to comment.