| 1 | |
| 2 | |
| 3 | @@ -3,7 +3,6 @@
|
| 4 | #include "itextstream.h"
|
| 5 |
|
| 6 | #ifdef POSIX
|
| 7 | -#include <execinfo.h>
|
| 8 | #include <signal.h>
|
| 9 | #endif
|
| 10 |
|
| 11 | @@ -21,24 +21,6 @@
|
| 12 | #ifdef POSIX
|
| 13 | rError() << "SIGSEGV signal caught: " << sig << std::endl;
|
| 14 | std::cerr << "SIGSEGV signal caught: " << sig << std::endl;
|
| 15 | -
|
| 16 | - void* buffer[100];
|
| 17 | - int numAddresses = backtrace(buffer, sizeof(buffer));
|
| 18 | - char** strings = backtrace_symbols(buffer, numAddresses);
|
| 19 | -
|
| 20 | - if (strings == nullptr)
|
| 21 | - {
|
| 22 | - std::cerr << "backtrace() returned nullptr" << std::endl;
|
| 23 | - exit(EXIT_FAILURE);
|
| 24 | - }
|
| 25 | -
|
| 26 | - for (int j = 0; j < numAddresses; j++)
|
| 27 | - {
|
| 28 | - rError() << j << ": " << strings[j] << std::endl;
|
| 29 | - std::cerr << j << ": " << strings[j] << std::endl;
|
| 30 | - }
|
| 31 | -
|
| 32 | - free(strings);
|
| 33 | exit(1);
|
| 34 | #endif
|
| 35 | }
|
| 36 |
|