From 7e5452d7d28539181b7624d6befe4da97d73252c Mon Sep 17 00:00:00 2001 From: baldurk Date: Sun, 6 Sep 2026 11:12:09 +0100 Subject: [PATCH] Add rare potential extra failures to process dying on startup --- renderdoc/os/win32/win32_process.cpp | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/renderdoc/os/win32/win32_process.cpp b/renderdoc/os/win32/win32_process.cpp index 052cc76b5..ce52f8b18 100644 --- a/renderdoc/os/win32/win32_process.cpp +++ b/renderdoc/os/win32/win32_process.cpp @@ -980,11 +980,20 @@ rdcpair Process::InjectIntoProcess(uint32_t pid, if(loc == 0) { + const char *largeAddrMsg = +#if ENABLED(RDOC_X64) + ", and is not built with /LARGEADDRESSAWARE:NO"; +#else + ""; +#endif + SET_ERROR_RESULT( result.first, ResultCode::InjectionFailed, "Failed to inject %s.dll into process. Check that the process did not crash or exit " - "early in initialisation, e.g. if the working directory is incorrectly set.", - rdoc_dll); + "early in initialisation, e.g. if the working directory is incorrectly set.\n" + "Otherwise ensure the program does not have significant " + "code that will run on global constructors/thread start and crash%s", + rdoc_dll, largeAddrMsg); } else {