diff options
author | Anthony G. Basile <blueness@gentoo.org> | 2012-07-27 17:57:19 -0400 |
---|---|---|
committer | Anthony G. Basile <blueness@gentoo.org> | 2012-07-27 17:57:19 -0400 |
commit | b3e9ab5db62e344bfe72b78c6ab7fcfebf6d9592 (patch) | |
tree | 15d0fea0e5701fd7c5065b29d3c3249288fbce21 /src | |
parent | tests/gnustack: switch from yasm to gcc for assembler (diff) | |
download | elfix-b3e9ab5db62e344bfe72b78c6ab7fcfebf6d9592.tar.gz elfix-b3e9ab5db62e344bfe72b78c6ab7fcfebf6d9592.tar.bz2 elfix-b3e9ab5db62e344bfe72b78c6ab7fcfebf6d9592.zip |
Revert "src/{fix-gnustack.c,paxctl-ng.c}: ELF_C_RDWR_MMAP -> ELF_C_RDWR for uclibc compat"
This reverts commit 02640d9d23cc4736e642600430b13406c33dba9e.
Using libelf instead of elfutils to gelf_update_phdr() fails. Revert
for now until we figure out what's going on.
Diffstat (limited to 'src')
-rw-r--r-- | src/fix-gnustack.c | 2 | ||||
-rw-r--r-- | src/paxctl-ng.c | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/src/fix-gnustack.c b/src/fix-gnustack.c index 03da236..15e23e0 100644 --- a/src/fix-gnustack.c +++ b/src/fix-gnustack.c @@ -99,7 +99,7 @@ main( int argc, char *argv[]) { if((fd = open(f_name, O_RDWR)) < 0) error(EXIT_FAILURE, 0, "open() fail."); - if((elf = elf_begin(fd, ELF_C_RDWR, NULL)) == NULL) + if((elf = elf_begin(fd, ELF_C_RDWR_MMAP, NULL)) == NULL) error(EXIT_FAILURE, 0, "elf_begin() fail: %s", elf_errmsg(elf_errno())); } else diff --git a/src/paxctl-ng.c b/src/paxctl-ng.c index 4b7e6fb..025ea24 100644 --- a/src/paxctl-ng.c +++ b/src/paxctl-ng.c @@ -216,7 +216,7 @@ get_pt_flags(int fd, int verbose) return pt_flags; } - if((elf = elf_begin(fd, ELF_C_READ, NULL)) == NULL) + if((elf = elf_begin(fd, ELF_C_READ_MMAP, NULL)) == NULL) { if(verbose) printf("\tELF ERROR: elf_begin() fail: %s\n", elf_errmsg(elf_errno())); @@ -460,7 +460,7 @@ set_pt_flags(int fd, uint16_t pt_flags, int verbose) return; } - if((elf = elf_begin(fd, ELF_C_RDWR, NULL)) == NULL) + if((elf = elf_begin(fd, ELF_C_RDWR_MMAP, NULL)) == NULL) { if(verbose) printf("\tELF ERROR: elf_begin() fail: %s\n", elf_errmsg(elf_errno())); |