More gnuhash fixes.
This commit is contained in:
parent
2a58041f7b
commit
b64f3cbad8
@ -10,7 +10,7 @@ diff -urpd ltrace-0.5-orig/elf.c ltrace-0.5/elf.c
|
||||
data = elf_getdata(scn, NULL);
|
||||
if (data == NULL || elf_getdata(scn, data) != NULL
|
||||
|| data->d_off || data->d_size != shdr.sh_size)
|
||||
@@ -209,6 +211,33 @@ static void do_init_elf(struct ltelf *lt
|
||||
@@ -209,6 +211,30 @@ static void do_init_elf(struct ltelf *lt
|
||||
error(EXIT_FAILURE, 0,
|
||||
"Unknown .hash sh_entsize in \"%s\"",
|
||||
filename);
|
||||
@ -22,10 +22,11 @@ diff -urpd ltrace-0.5-orig/elf.c ltrace-0.5/elf.c
|
||||
+
|
||||
+ lte->hash_type = SHT_GNU_HASH;
|
||||
+
|
||||
+ if (shdr.sh_entsize != 0) {
|
||||
+ if (shdr.sh_entsize != 0
|
||||
+ && shdr.sh_entsize != 4) {
|
||||
+ error(EXIT_FAILURE, 0,
|
||||
+ ".gnu.hash sh_entsize in \"%s\" should be 0",
|
||||
+ filename);
|
||||
+ ".gnu.hash sh_entsize in \"%s\" should be 4, but is %d",
|
||||
+ filename, shdr.sh_entsize);
|
||||
+ }
|
||||
+
|
||||
+ data = elf_getdata(scn, NULL);
|
||||
@ -35,10 +36,6 @@ diff -urpd ltrace-0.5-orig/elf.c ltrace-0.5/elf.c
|
||||
+ "Couldn't get .gnu.hash data from \"%s\"",
|
||||
+ filename);
|
||||
+
|
||||
+ if (data->d_type != ELF_T_GNUHASH)
|
||||
+ error(EXIT_FAILURE, 0,
|
||||
+ "Couldn't get .gnu.hash data from \"%s\"",
|
||||
+ filename);
|
||||
+ lte->hash = (Elf32_Word *) data->d_buf;
|
||||
+#endif
|
||||
} else if (shdr.sh_type == SHT_PROGBITS
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
Summary: Tracks runtime library calls from dynamically linked executables.
|
||||
Name: ltrace
|
||||
Version: 0.5
|
||||
Release: 1.0.45svn.3
|
||||
Release: 1.0.45svn.4
|
||||
Source: ltrace-0.5.tar.gz
|
||||
Patch2: ltrace-opd.patch
|
||||
Patch3: ltrace-ppc32fc5.patch
|
||||
@ -56,7 +56,7 @@ rm -rf $RPM_BUILD_ROOT
|
||||
%config /etc/ltrace.conf
|
||||
|
||||
%changelog
|
||||
* Fri Jul 14 2006 Petr Machata <pmachata@redhat.com> - 0.5-1.0.45svn.3
|
||||
* Fri Jul 14 2006 Petr Machata <pmachata@redhat.com> - 0.5-1.0.45svn.4
|
||||
- adding .gnu.hash patch to support new ELF hash table section
|
||||
- adding testsuite patch to silent some bogus failures
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user