From 6ba2c24cc4f04311e48a35e5c43847205f511acc Mon Sep 17 00:00:00 2001 From: naruse Date: Mon, 31 Mar 2014 22:34:41 +0000 Subject: [PATCH] * vm_dump.c (rb_print_backtrace): current implementation uses dladdr to get the path of objects. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@45489 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ChangeLog | 5 +++++ vm_dump.c | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 6e4c47054f..c911571456 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +Tue Apr 1 07:27:15 2014 NARUSE, Yui + + * vm_dump.c (rb_print_backtrace): current implementation + uses dladdr to get the path of objects. + Mon Mar 31 23:57:45 2014 Nobuyoshi Nakada * ext/readline/extconf.rb: fix typo, `$defs` not `$DEFS`. diff --git a/vm_dump.c b/vm_dump.c index 23f0e571cf..92e701c098 100644 --- a/vm_dump.c +++ b/vm_dump.c @@ -683,7 +683,7 @@ rb_print_backtrace(void) #define MAX_NATIVE_TRACE 1024 static void *trace[MAX_NATIVE_TRACE]; int n = backtrace(trace, MAX_NATIVE_TRACE); -#ifdef USE_ELF +#if defined(USE_ELF) && defined(HAVE_DLADDR) rb_dump_backtrace_with_lines(n, trace); #else char **syms = backtrace_symbols(trace, n);