for (scope = symbol_scope; *scope; ++scope)
if (do_lookup (undef_name, hash, *ref, ¤t_value, *scope, 0, flags,
NULL, type_class))
- {
- /* We have to check whether this would bind UNDEF_MAP to an object
- in the global scope which was dynamically loaded. In this case
- we have to prevent the latter from being unloaded unless the
- UNDEF_MAP object is also unloaded. */
- if (__builtin_expect (current_value.m->l_type == lt_loaded, 0)
- /* Don't do this for explicit lookups as opposed to implicit
- runtime lookups. */
- && (flags & DL_LOOKUP_ADD_DEPENDENCY) != 0
- /* Add UNDEF_MAP to the dependencies. */
- && add_dependency (undef_map, current_value.m) < 0)
- /* Something went wrong. Perhaps the object we tried to reference
- was just removed. Try finding another definition. */
- return INTUSE(_dl_lookup_symbol) (undef_name, undef_map, ref,
- symbol_scope, type_class, 0);
-
- break;
- }
+ break;
if (__builtin_expect (current_value.s == NULL, 0))
{
protected = *ref && ELFW(ST_VISIBILITY) ((*ref)->st_other) == STV_PROTECTED;
if (__builtin_expect (protected != 0, 0))
{
- /* It is very tricky. We need to figure out what value to
- return for the protected symbol */
+ /* It is very tricky. We need to figure out what value to
+ return for the protected symbol. */
struct sym_val protected_value = { NULL, NULL };
for (scope = symbol_scope; *scope; ++scope)
}
}
+ /* We have to check whether this would bind UNDEF_MAP to an object
+ in the global scope which was dynamically loaded. In this case
+ we have to prevent the latter from being unloaded unless the
+ UNDEF_MAP object is also unloaded. */
+ if (__builtin_expect (current_value.m->l_type == lt_loaded, 0)
+ /* Don't do this for explicit lookups as opposed to implicit
+ runtime lookups. */
+ && (flags & DL_LOOKUP_ADD_DEPENDENCY) != 0
+ /* Add UNDEF_MAP to the dependencies. */
+ && add_dependency (undef_map, current_value.m) < 0)
+ /* Something went wrong. Perhaps the object we tried to reference
+ was just removed. Try finding another definition. */
+ return INTUSE(_dl_lookup_symbol) (undef_name, undef_map, ref,
+ symbol_scope, type_class, flags);
+
if (__builtin_expect (GL(dl_debug_mask)
& (DL_DEBUG_BINDINGS|DL_DEBUG_PRELINK), 0))
_dl_debug_bindings (undef_name, undef_map, ref, symbol_scope,
int res = do_lookup_versioned (undef_name, hash, *ref, ¤t_value,
*scope, 0, version, NULL, type_class);
if (res > 0)
- {
- /* We have to check whether this would bind UNDEF_MAP to an object
- in the global scope which was dynamically loaded. In this case
- we have to prevent the latter from being unloaded unless the
- UNDEF_MAP object is also unloaded. */
- if (__builtin_expect (current_value.m->l_type == lt_loaded, 0)
- /* Don't do this for explicit lookups as opposed to implicit
- runtime lookups. */
- && flags != 0
- /* Add UNDEF_MAP to the dependencies. */
- && add_dependency (undef_map, current_value.m) < 0)
- /* Something went wrong. Perhaps the object we tried to reference
- was just removed. Try finding another definition. */
- return INTUSE(_dl_lookup_versioned_symbol) (undef_name, undef_map,
- ref, symbol_scope,
- version, type_class,
- 0);
-
- break;
- }
+ break;
if (__builtin_expect (res, 0) < 0)
{
if (__builtin_expect (protected != 0, 0))
{
- /* It is very tricky. We need to figure out what value to
- return for the protected symbol */
+ /* It is very tricky. We need to figure out what value to
+ return for the protected symbol. */
struct sym_val protected_value = { NULL, NULL };
for (scope = symbol_scope; *scope; ++scope)
}
}
+ /* We have to check whether this would bind UNDEF_MAP to an object
+ in the global scope which was dynamically loaded. In this case
+ we have to prevent the latter from being unloaded unless the
+ UNDEF_MAP object is also unloaded. */
+ if (__builtin_expect (current_value.m->l_type == lt_loaded, 0)
+ /* Don't do this for explicit lookups as opposed to implicit
+ runtime lookups. */
+ && flags != 0
+ /* Add UNDEF_MAP to the dependencies. */
+ && add_dependency (undef_map, current_value.m) < 0)
+ /* Something went wrong. Perhaps the object we tried to reference
+ was just removed. Try finding another definition. */
+ return INTUSE(_dl_lookup_versioned_symbol) (undef_name, undef_map,
+ ref, symbol_scope,
+ version, type_class, flags);
+
if (__builtin_expect (GL(dl_debug_mask)
& (DL_DEBUG_BINDINGS|DL_DEBUG_PRELINK), 0))
_dl_debug_bindings (undef_name, undef_map, ref, symbol_scope,
if (__builtin_expect (protected != 0, 0))
{
- /* It is very tricky. We need to figure out what value to
- return for the protected symbol */
+ /* It is very tricky. We need to figure out what value to
+ return for the protected symbol. */
struct sym_val protected_value = { NULL, NULL };
if (i >= (*scope)->r_nlist