diff options
| author | Shauren <shauren.trinity@gmail.com> | 2025-10-27 09:55:50 +0100 |
|---|---|---|
| committer | Shauren <shauren.trinity@gmail.com> | 2025-10-27 09:55:50 +0100 |
| commit | 29539aa4de3e1f1afc62a9797a9ca2f0fc37ffc9 (patch) | |
| tree | 1150e0608797008878a6a77042a12a423fc0c82c | |
| parent | 33de27c5b9ab0bcf106025012bdc3f8c5ec0f307 (diff) | |
Core/CrashHandler: Fix clang warnings
| -rw-r--r-- | src/common/Debugging/Windows/WheatyExceptionReport.cpp | 16 |
1 files changed, 4 insertions, 12 deletions
diff --git a/src/common/Debugging/Windows/WheatyExceptionReport.cpp b/src/common/Debugging/Windows/WheatyExceptionReport.cpp index fd233317268..0c2cf42a682 100644 --- a/src/common/Debugging/Windows/WheatyExceptionReport.cpp +++ b/src/common/Debugging/Windows/WheatyExceptionReport.cpp @@ -1824,7 +1824,7 @@ size_t countOverride) if (basicType == btFloat) pszCurrBuffer += snprintf(pszCurrBuffer, bufferSize, "%f", *(PFLOAT)pAddress); else - pszCurrBuffer += snprintf(pszCurrBuffer, bufferSize, "0x%X", *(PDWORD)pAddress); + pszCurrBuffer += snprintf(pszCurrBuffer, bufferSize, "0x%lX", *(PDWORD)pAddress); } else if (length == 8) { @@ -1834,27 +1834,19 @@ size_t countOverride) *(double *)pAddress); } else - pszCurrBuffer += snprintf(pszCurrBuffer, bufferSize, "0x%I64X", + pszCurrBuffer += snprintf(pszCurrBuffer, bufferSize, "0x%llX", *(DWORD64*)pAddress); } else { - #if _WIN64 - pszCurrBuffer += snprintf(pszCurrBuffer, bufferSize, "0x%I64X", (DWORD64)pAddress); - #else - pszCurrBuffer += snprintf(pszCurrBuffer, bufferSize, "0x%X", (DWORD)pAddress); - #endif + pszCurrBuffer += snprintf(pszCurrBuffer, bufferSize, "%p", pAddress); } break; } } __except (EXCEPTION_EXECUTE_HANDLER) { -#if _WIN64 - pszCurrBuffer += snprintf(pszCurrBuffer, bufferSize, "0x%I64X <Unable to read memory>", (DWORD64)pAddress); -#else - pszCurrBuffer += snprintf(pszCurrBuffer, bufferSize, "0x%X <Unable to read memory>", (DWORD)pAddress); -#endif + pszCurrBuffer += snprintf(pszCurrBuffer, bufferSize, "%p <Unable to read memory>", pAddress); } } |
