]> git.lyx.org Git - lyx.git/blobdiff - src/support/debug.cpp
Minor cleanup.
[lyx.git] / src / support / debug.cpp
index 92d93bacd75309a549197b3e2947df1e24a8f6fd..29a167af917418a242c46100a9926cd7e41a788b 100644 (file)
 #include <iostream>
 #include <iomanip>
 
-//#define LYX_CALLSTACK_PRINTING
-// must be linked with -rdynamic
-#ifdef LYX_CALLSTACK_PRINTING
-#include <stdio.h>
-#include <stdlib.h>
-#include <execinfo.h>
-#endif
-
-
 
 using namespace std;
 using namespace lyx::support;
@@ -253,22 +244,5 @@ LyXErr & operator<<(LyXErr & l, ios_base &(*t)(ios_base &))
 LyXErr lyxerr;
 
 
-void Debug::printCallStack()
-{
-#ifdef LYX_CALLSTACK_PRINTING
-       const int depth = 50;
-       
-       // get void*'s for all entries on the stack
-       void* array[depth];
-       size_t size = backtrace(array, depth);
-       
-       char** messages = backtrace_symbols(array, size);
-       
-       for (size_t i = 0; i < size && messages != NULL; i++) {
-               fprintf(stderr, "[LyX's bt]: (%d) %s\n", i, messages[i]);
-       }
-#endif
-}
-
 
 } // namespace lyx