* Thu Jul 23 2009 Adam Jackson <ajax@redhat.com> 1.6.99-16.20090721
- xserver-1.6.99-linkmap.patch: Print load offsets of all DSOs on backtrace so we addr2line afterwards.
This commit is contained in:
parent
5458ee37a9
commit
08ecc6840b
@ -19,7 +19,7 @@
|
||||
Summary: X.Org X11 X server
|
||||
Name: xorg-x11-server
|
||||
Version: 1.6.99
|
||||
Release: 15.%{gitdate}%{?dist}
|
||||
Release: 16.%{gitdate}%{?dist}
|
||||
URL: http://www.x.org
|
||||
License: MIT
|
||||
Group: User Interface/X
|
||||
@ -46,6 +46,8 @@ Source20: http://svn.exactcode.de/t2/trunk/package/xorg/xorg-server/xvfb-run.sh
|
||||
Source30: find-provides
|
||||
#define __find_provides {nil}
|
||||
|
||||
Patch10: xserver-1.6.99-linkmap.patch
|
||||
|
||||
# OpenGL compositing manager feature/optimization patches.
|
||||
Patch103: xserver-1.5.0-bg-none-root.patch
|
||||
|
||||
@ -521,6 +523,10 @@ rm -rf $RPM_BUILD_ROOT
|
||||
|
||||
|
||||
%changelog
|
||||
* Thu Jul 23 2009 Adam Jackson <ajax@redhat.com> 1.6.99-16.20090721
|
||||
- xserver-1.6.99-linkmap.patch: Print load offsets of all DSOs on backtrace
|
||||
so we addr2line afterwards.
|
||||
|
||||
* Tue Jul 21 2009 Adam Jackson <ajax@redhat.com> 1.6.99-15.20090721
|
||||
- Today's git snapshot.
|
||||
|
||||
|
51
xserver-1.6.99-linkmap.patch
Normal file
51
xserver-1.6.99-linkmap.patch
Normal file
@ -0,0 +1,51 @@
|
||||
From edf055d2733a0e012dfd97daf1906c407c47ff88 Mon Sep 17 00:00:00 2001
|
||||
From: Adam Jackson <ajax@redhat.com>
|
||||
Date: Thu, 23 Jul 2009 14:43:30 -0400
|
||||
Subject: [PATCH] dix: Print load map on backtrace
|
||||
|
||||
---
|
||||
os/backtrace.c | 16 ++++++++++++++++
|
||||
1 files changed, 16 insertions(+), 0 deletions(-)
|
||||
|
||||
diff --git a/os/backtrace.c b/os/backtrace.c
|
||||
index 3cfae3e..af67301 100644
|
||||
--- a/os/backtrace.c
|
||||
+++ b/os/backtrace.c
|
||||
@@ -30,18 +30,34 @@
|
||||
|
||||
#ifdef HAVE_BACKTRACE
|
||||
#include <execinfo.h>
|
||||
+#include <dlfcn.h>
|
||||
+#include <link.h>
|
||||
|
||||
void xorg_backtrace(void)
|
||||
{
|
||||
void *array[32]; /* deeper nesting than this means something's wrong */
|
||||
int size, i;
|
||||
char **strings;
|
||||
+ struct link_map *lm;
|
||||
+ void *self;
|
||||
+
|
||||
ErrorF("\nBacktrace:\n");
|
||||
size = backtrace(array, 32);
|
||||
strings = backtrace_symbols(array, size);
|
||||
for (i = 0; i < size; i++)
|
||||
ErrorF("%d: %s\n", i, strings[i]);
|
||||
free(strings);
|
||||
+
|
||||
+ self = dlopen(NULL, RTLD_LAZY);
|
||||
+ dlinfo(self, RTLD_DI_LINKMAP, &lm);
|
||||
+
|
||||
+ ErrorF("\nLink map:\n");
|
||||
+ while (lm) {
|
||||
+ if (lm->l_addr)
|
||||
+ ErrorF("%p: %s\n", (void *)lm->l_addr,
|
||||
+ lm->l_name[0] ? lm->l_name : "(vdso)");
|
||||
+ lm = lm->l_next;
|
||||
+ }
|
||||
}
|
||||
|
||||
#else /* not glibc or glibc < 2.1 */
|
||||
--
|
||||
1.6.3.3
|
||||
|
Loading…
Reference in New Issue
Block a user