aboutsummaryrefslogtreecommitdiff
path: root/elf
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@gmail.com>2011-05-22 21:30:31 -0400
committerUlrich Drepper <drepper@gmail.com>2011-05-22 21:30:31 -0400
commitde7ce8f171b88b2db025fdb6c8cca89c16e541dc (patch)
treeffe7a3ea3630f8437d1781201bfb5d1a9bf77b47 /elf
parent05bb4a68ad7b05e16f942552a867da6ffb88278f (diff)
downloadglibc-de7ce8f171b88b2db025fdb6c8cca89c16e541dc.zip
glibc-de7ce8f171b88b2db025fdb6c8cca89c16e541dc.tar.gz
glibc-de7ce8f171b88b2db025fdb6c8cca89c16e541dc.tar.bz2
Fix flags parameter value passed to pltenter and pltexit
Diffstat (limited to 'elf')
-rw-r--r--elf/dl-runtime.c12
1 files changed, 5 insertions, 7 deletions
diff --git a/elf/dl-runtime.c b/elf/dl-runtime.c
index ae2d05c..b27cfbf 100644
--- a/elf/dl-runtime.c
+++ b/elf/dl-runtime.c
@@ -271,7 +271,7 @@ _dl_profile_fixup (
interested in auditing. */
if ((l->l_audit_any_plt | result->l_audit_any_plt) != 0)
{
- unsigned int altvalue = 0;
+ unsigned int flags = 0;
struct audit_ifaces *afct = GLRO(dl_audit);
/* Synthesize a symbol record where the st_value field is
the result. */
@@ -294,7 +294,6 @@ _dl_profile_fixup (
if ((l->l_audit[cnt].bindflags & LA_FLG_BINDFROM) != 0
&& (result->l_audit[cnt].bindflags & LA_FLG_BINDTO) != 0)
{
- unsigned int flags = altvalue;
if (afct->symbind != NULL)
{
uintptr_t new_value
@@ -305,7 +304,7 @@ _dl_profile_fixup (
strtab2 + defsym->st_name);
if (new_value != (uintptr_t) sym.st_value)
{
- altvalue = LA_SYMB_ALTVALUE;
+ flags |= LA_SYMB_ALTVALUE;
sym.st_value = new_value;
}
}
@@ -328,7 +327,7 @@ _dl_profile_fixup (
afct = afct->next;
}
- reloc_result->flags = altvalue;
+ reloc_result->flags = flags;
value = DL_FIXUP_ADDR_VALUE (sym.st_value);
}
else
@@ -366,7 +365,7 @@ _dl_profile_fixup (
const char *symname = strtab + sym.st_name;
/* Keep track of overwritten addresses. */
- unsigned int altvalue = reloc_result->flags;
+ unsigned int flags = reloc_result->flags;
struct audit_ifaces *afct = GLRO(dl_audit);
for (unsigned int cnt = 0; cnt < GLRO(dl_naudit); ++cnt)
@@ -375,7 +374,6 @@ _dl_profile_fixup (
&& (reloc_result->enterexit
& (LA_SYMB_NOPLTENTER << (2 * (cnt + 1)))) == 0)
{
- unsigned int flags = altvalue;
long int new_framesize = -1;
uintptr_t new_value
= afct->ARCH_LA_PLTENTER (&sym, reloc_result->boundndx,
@@ -385,7 +383,7 @@ _dl_profile_fixup (
&new_framesize);
if (new_value != (uintptr_t) sym.st_value)
{
- altvalue = LA_SYMB_ALTVALUE;
+ flags |= LA_SYMB_ALTVALUE;
sym.st_value = new_value;
}