Created
March 8, 2013 15:32
-
-
Save kaworu/5117240 to your computer and use it in GitHub Desktop.
gcc48 pkgng patch (libelf)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/external/libelf/elf_update.c b/external/libelf/elf_update.c | |
index 900ed2a..d5d41e3 100644 | |
--- a/external/libelf/elf_update.c | |
+++ b/external/libelf/elf_update.c | |
@@ -502,7 +502,7 @@ _libelf_resync_sections(Elf *e, off_t rc, struct _Elf_Extent_List *extents) | |
static off_t | |
_libelf_resync_elf(Elf *e, struct _Elf_Extent_List *extents) | |
{ | |
- int ec, eh_class, eh_type; | |
+ int ec, eh_class; | |
unsigned int eh_byteorder, eh_version; | |
size_t align, fsz; | |
size_t phnum, shnum; | |
@@ -531,14 +531,12 @@ _libelf_resync_elf(Elf *e, struct _Elf_Extent_List *extents) | |
eh_class = eh32->e_ident[EI_CLASS]; | |
phoff = (uint64_t) eh32->e_phoff; | |
shoff = (uint64_t) eh32->e_shoff; | |
- eh_type = eh32->e_type; | |
eh_version = eh32->e_version; | |
} else { | |
eh_byteorder = eh64->e_ident[EI_DATA]; | |
eh_class = eh64->e_ident[EI_CLASS]; | |
phoff = eh64->e_phoff; | |
shoff = eh64->e_shoff; | |
- eh_type = eh64->e_type; | |
eh_version = eh64->e_version; | |
} | |
diff --git a/external/libelf/libelf_phdr.c b/external/libelf/libelf_phdr.c | |
index 8495e42..b9a59a5 100644 | |
--- a/external/libelf/libelf_phdr.c | |
+++ b/external/libelf/libelf_phdr.c | |
@@ -38,7 +38,7 @@ ELFTC_VCSID("$Id: libelf_phdr.c 2225 2011-11-26 18:55:54Z jkoshy $"); | |
void * | |
_libelf_getphdr(Elf *e, int ec) | |
{ | |
- size_t phnum, phentsize; | |
+ size_t phnum; | |
size_t fsz, msz; | |
uint64_t phoff; | |
Elf32_Ehdr *eh32; | |
@@ -69,11 +69,9 @@ _libelf_getphdr(Elf *e, int ec) | |
if (ec == ELFCLASS32) { | |
eh32 = (Elf32_Ehdr *) ehdr; | |
- phentsize = eh32->e_phentsize; | |
phoff = (uint64_t) eh32->e_phoff; | |
} else { | |
eh64 = (Elf64_Ehdr *) ehdr; | |
- phentsize = eh64->e_phentsize; | |
phoff = (uint64_t) eh64->e_phoff; | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This should be reviewed and submitted upstream if relevant.