From 1d00bbe01bcd0bdc74961a225c78eb24e3e1b77b Mon Sep 17 00:00:00 2001 From: Davi Arnaut Date: Thu, 19 Jun 2008 13:00:53 -0300 Subject: [PATCH] Silence unused variable warning by printing the variables value. mysys/stacktrace.c: Print stack bottom and thread stack values as they might be useful. --- mysys/stacktrace.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/mysys/stacktrace.c b/mysys/stacktrace.c index 9ae3d88ef50..5b941bbd7d6 100644 --- a/mysys/stacktrace.c +++ b/mysys/stacktrace.c @@ -109,6 +109,8 @@ void my_print_stacktrace(uchar* stack_bottom, ulong thread_stack) void *addrs[128]; char **strings= NULL; int n = backtrace(addrs, array_elements(addrs)); + fprintf(stderr, "stack_bottom = %p thread_stack 0x%lx\n", + stack_bottom, thread_stack); #if BACKTRACE_DEMANGLE if ((strings= backtrace_symbols(addrs, n))) {