Nurdin Premji wrote:
Can this be committed?
This forces the memory mapped in from the inferior process to be mapped
only into the first 32 bits of memory. This avoids the situation of
truncated memory addresses when unwinding a 32 bit process on a 64 bit
host.
--- libunwind-0.99-alpha/src/elfxx.h 2006-07-26 23:13:14.000000000 -0400
+++ mainworkspace/frysk/frysk-imports/libunwind/src/elfxx.h 2007-04-24 16:42:55.000000000 -0400
@@ -1,6 +1,7 @@
/* libunwind - a platform-independent unwind library
Copyright (C) 2003, 2005 Hewlett-Packard Co
Contributed by David Mosberger-Tang <[EMAIL PROTECTED]>
+ Copyright Red Hat 2007
This file is part of libunwind.
@@ -42,6 +43,10 @@
# define elf_w(x) _Uelf64_##x
#endif
+#ifndef MAP_32BIT
+# define MAP_32BIT 0
+#endif
+
static inline int
elf_map_image (struct elf_image *ei, const char *path)
{
@@ -59,7 +64,7 @@
}
ei->size = stat.st_size;
- ei->image = mmap (NULL, ei->size, PROT_READ, MAP_PRIVATE, fd, 0);
+ ei->image = mmap (NULL, ei->size, PROT_READ, MAP_PRIVATE | MAP_32BIT, fd, 0);
close (fd);
if (ei->image == MAP_FAILED)
return -1;
_______________________________________________
Libunwind-devel mailing list
[email protected]
http://lists.nongnu.org/mailman/listinfo/libunwind-devel