Skip to content

Commit

Permalink
Add separator around stacktraces in scan-log
Browse files Browse the repository at this point in the history
  • Loading branch information
x42 committed Jul 12, 2021
1 parent 2ee5082 commit 5ddb887
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 10 deletions.
5 changes: 3 additions & 2 deletions libs/auscan/au-scanner.cc
Original file line number Diff line number Diff line change
Expand Up @@ -99,8 +99,9 @@ scan_auv2 (CAComponentDescription& desc, bool force, bool verbose)
static void
sig_handler (int sig)
{
fprintf (stderr, "Error: signal %d\n", sig);
PBD::stacktrace (cerr, 15, 2);
printf ("Error: signal %d\n ---8<---\n", sig);
PBD::stacktrace (std::cout,, 15, 2);
printf (" --->8---\n");
::exit (EXIT_FAILURE);
}

Expand Down
10 changes: 6 additions & 4 deletions libs/fst/vst2-scanner.cc
Original file line number Diff line number Diff line change
Expand Up @@ -135,16 +135,18 @@ static LONG WINAPI
crash_handler (EXCEPTION_POINTERS* exceptioninfo)
{
// TODO consider DrMingw if HAVE_DRMINGW
fprintf (stderr, "Error: %x\n", exceptioninfo->ExceptionRecord->ExceptionCode);
PBD::stacktrace (cerr, 15, 2);
printf ("Error: %x\n ---8<---\n", exceptioninfo->ExceptionRecord->ExceptionCode);
PBD::stacktrace (std::cout, 15, 2);
printf (" --->8---\n");
return EXCEPTION_CONTINUE_SEARCH;
}
#else
static void
sig_handler (int sig)
{
fprintf (stderr, "Error: signal %d\n", sig);
PBD::stacktrace (cerr, 15, 2);
printf ("Error: signal %d\n ---8<---\n", sig);
PBD::stacktrace (std::cout, 15, 2);
printf (" --->8---\n");
::exit (EXIT_FAILURE);
}
#endif
Expand Down
10 changes: 6 additions & 4 deletions libs/fst/vst3-scanner.cc
Original file line number Diff line number Diff line change
Expand Up @@ -122,16 +122,18 @@ static LONG WINAPI
crash_handler (EXCEPTION_POINTERS* exceptioninfo)
{
// TODO consider DrMingw if HAVE_DRMINGW
fprintf (stderr, "Error: %x\n", exceptioninfo->ExceptionRecord->ExceptionCode);
PBD::stacktrace (cerr, 15, 2);
printf ("Error: %x\n ---8<---\n", exceptioninfo->ExceptionRecord->ExceptionCode);
PBD::stacktrace (std::cout, 15, 2);
printf (" --->8---\n");
return EXCEPTION_CONTINUE_SEARCH;
}
#else
static void
sig_handler (int sig)
{
fprintf (stderr, "Error: signal %d\n", sig);
PBD::stacktrace (cerr, 15, 2);
printf ("Error: signal %d\n ---8<---\n", sig);
PBD::stacktrace (std::cout, 15, 2);
printf (" --->8---\n");
::exit (EXIT_FAILURE);
}
#endif
Expand Down

0 comments on commit 5ddb887

Please sign in to comment.