mirror of
git://sourceware.org/git/glibc.git
synced 2025-03-06 20:58:33 +01:00
elf: avoid jumping over a needed declaration
The declaration of found_other_class could be jumped over via the goto just above it, but the code jumped to uses found_other_class. Move the declaration up a bit to ensure it's properly declared and initialized.
This commit is contained in:
parent
12b8dd7718
commit
8e57206797
1 changed files with 3 additions and 3 deletions
|
@ -1931,6 +1931,9 @@ _dl_map_object (struct link_map *loader, const char *name,
|
||||||
: "\nfile=%s [%lu]; dynamically loaded by %s [%lu]\n",
|
: "\nfile=%s [%lu]; dynamically loaded by %s [%lu]\n",
|
||||||
name, nsid, DSO_FILENAME (loader->l_name), loader->l_ns);
|
name, nsid, DSO_FILENAME (loader->l_name), loader->l_ns);
|
||||||
|
|
||||||
|
/* Will be true if we found a DSO which is of the other ELF class. */
|
||||||
|
bool found_other_class = false;
|
||||||
|
|
||||||
#ifdef SHARED
|
#ifdef SHARED
|
||||||
/* Give the auditing libraries a chance to change the name before we
|
/* Give the auditing libraries a chance to change the name before we
|
||||||
try anything. */
|
try anything. */
|
||||||
|
@ -1948,9 +1951,6 @@ _dl_map_object (struct link_map *loader, const char *name,
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* Will be true if we found a DSO which is of the other ELF class. */
|
|
||||||
bool found_other_class = false;
|
|
||||||
|
|
||||||
if (strchr (name, '/') == NULL)
|
if (strchr (name, '/') == NULL)
|
||||||
{
|
{
|
||||||
/* Search for NAME in several places. */
|
/* Search for NAME in several places. */
|
||||||
|
|
Loading…
Add table
Reference in a new issue