From ea9e4be269baf2ad8db3e23500315083b9cc0df0 Mon Sep 17 00:00:00 2001 From: Chris Wilson Date: Tue, 31 Aug 2010 13:59:29 +0000 Subject: Fix demangled logging of backtraces on OSX by using dladdr to get function names rather than trying to parse the results of backtrace_strings(). --- lib/common/Utils.cpp | 148 +++++++++++++++++++++++++++++---------------------- 1 file changed, 85 insertions(+), 63 deletions(-) (limited to 'lib/common') diff --git a/lib/common/Utils.cpp b/lib/common/Utils.cpp index 6f21330d..6afafe84 100644 --- a/lib/common/Utils.cpp +++ b/lib/common/Utils.cpp @@ -24,6 +24,10 @@ #include #endif +#ifdef HAVE_DLFCN_H + #include +#endif + #include "Utils.h" #include "CommonException.h" #include "Logging.h" @@ -73,88 +77,106 @@ void SplitString(const std::string &String, char SplitOn, std::vector