introduce printing functions and their parameters on base of dwarf info

This commit is contained in:
2020-01-14 13:47:08 +04:00
parent fc6a81b460
commit eb9dc1341d
3 changed files with 87 additions and 21 deletions
+4 -2
View File
@@ -71,7 +71,9 @@ void FatalSignalHandler(int sig, siginfo_t* info, void* context)
}
if(trace) {
logger->Log(SEVERITY_DEBUG, "%s", handler.ctx.buff);
logger->Log(SEVERITY_INFO, "%s", handler.ctx.buff);
handler.print_dwarf();
logger->Log(SEVERITY_INFO, "%s", handler.ctx.buff);
} else {
logger->Log(SEVERITY_ERROR, "No stack trace obtained");
}
@@ -191,7 +193,7 @@ void ResetSignalHandler() {
int main(int argc, char* argv[])
{
logger->SetCurrentSeverity(SEVERITY_INFO);
SetSignalHandler(SigusrHandler);
Fun1(1, DEF_2, 5);