mirror of
https://github.com/boykopovar/AnyPS5.git
synced 2026-10-22 00:22:57 -05:00
The abort() and UCRT invalid-parameter reports capture the stack with RtlCaptureStackBackTrace, which stops at the first frame without unwind data (guest code, or our libraries built without asynchronous unwind tables), so they often end two or three frames in, before any caller. The fault report already scans the stack for code addresses; that scan is now a helper the backtrace reports use as well. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
13 lines
331 B
C++
13 lines
331 B
C++
#include <cstdio>
|
|
#include <cstdlib>
|
|
#include "../prx/libc/include/general/VabiMacros.hpp"
|
|
|
|
extern "C" int* APS5_VABI __error_nid_postfix();
|
|
|
|
int main() {
|
|
if (__error_nid_postfix() == nullptr) return 1;
|
|
_set_abort_behavior(0, _WRITE_ABORT_MSG | _CALL_REPORTFAULT);
|
|
std::fputs("aborting\n", stderr);
|
|
std::abort();
|
|
}
|