summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJamey Sharp <jamey@minilop.net>2009-10-08 13:38:01 +1100
committerDaniel Stone <daniel@fooishbar.org>2009-10-08 13:38:01 +1100
commitb680a89262efcfef4644adb4a61ae42ea0db0c93 (patch)
tree23667aa9af577e4be556e0e72b5f42f1ddb47f0a
parent9bf2ff4faf730913de3073f346646a8727be41d4 (diff)
Fix GCC warnings in xorg_backtrace
Signed-off-by: Jamey Sharp <jamey@minilop.net> Signed-off-by: Daniel Stone <daniel@fooishbar.org>
-rw-r--r--os/backtrace.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/os/backtrace.c b/os/backtrace.c
index a421140fb..dafb9904b 100644
--- a/os/backtrace.c
+++ b/os/backtrace.c
@@ -38,7 +38,7 @@
void xorg_backtrace(void)
{
void *array[64];
- char *mod;
+ const char *mod;
int size, i;
Dl_info info;
ErrorF("\nBacktrace:\n");
@@ -48,10 +48,10 @@ void xorg_backtrace(void)
mod = (info.dli_fname && *info.dli_fname) ? info.dli_fname : "(vdso)";
if (info.dli_saddr)
ErrorF("%d: %s (%s+0x%lx) [%p]\n", i, mod,
- info.dli_sname, array[i] - info.dli_saddr, array[i]);
+ info.dli_sname, (char *) array[i] - (char *) info.dli_saddr, array[i]);
else
ErrorF("%d: %s (%p+0x%lx) [%p]\n", i, mod,
- info.dli_fbase, array[i] - info.dli_fbase, array[i]);
+ info.dli_fbase, (char *) array[i] - (char *) info.dli_fbase, array[i]);
}
}