MCPcopy Create free account
hub / github.com/OpenStarbound/OpenStarbound / outputStack

Function outputStack

source/core/StarException_unix.cpp:36–50  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

34}
35
36OutputProxy outputStack(StackCapture stack) {
37 return OutputProxy([stack = std::move(stack)](std::ostream & os) {
38 char** symbols = backtrace_symbols(stack.first.ptr(), stack.second);
39 for (size_t i = 0; i < stack.second; ++i) {
40 os << symbols[i];
41 if (i + 1 < stack.second)
42 os << std::endl;
43 }
44
45 if (stack.second == StackLimit)
46 os << std::endl << "[Stack Output Limit Reached]";
47
48 ::free(symbols);
49 });
50}
51
52StarException::StarException() noexcept
53 : StarException(std::string("StarException")) {}

Callers 4

StarExceptionMethod · 0.70
printStackFunction · 0.70
fatalErrorFunction · 0.70
fatalExceptionFunction · 0.70

Calls 3

OutputProxyClass · 0.70
freeFunction · 0.70
ptrMethod · 0.45

Tested by

no test coverage detected