mirror of
git://sourceware.org/git/glibc.git
synced 2024-11-21 01:12:26 +08:00
Minor optimization of unloading prevention patch.
References to unique symbols from copy relocations can only come from executables which cannot be unloaded anyway. Optimize the code to set the unload flag a bit.
This commit is contained in:
parent
fe4d2935e8
commit
c15b1d20cd
@ -331,12 +331,12 @@ do_lookup_x (const char *undef_name, uint_fast32_t new_hash,
|
||||
{
|
||||
table[idx].sym = sym;
|
||||
table[idx].map = map;
|
||||
}
|
||||
|
||||
if (table[idx].map->l_type == lt_loaded)
|
||||
/* Make sure we don't unload this object by
|
||||
setting the appropriate flag. */
|
||||
table[idx].map->l_flags_1 |= DF_1_NODELETE;
|
||||
if (map->l_type == lt_loaded)
|
||||
/* Make sure we don't unload this object by
|
||||
setting the appropriate flag. */
|
||||
map->l_flags_1 |= DF_1_NODELETE;
|
||||
}
|
||||
|
||||
return;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user