mirror of
https://sourceware.org/git/glibc.git
synced 2025-12-24 17:51:17 +03:00
Avoid crashing in LD_DEBUG when program name is unavailable
Resolves: #15465 The program name may be unavailable if the user application tampers with argc and argv[]. Some parts of the dynamic linker caters for this while others don't, so this patch consolidates the check and fallback into a single macro and updates all users.
This commit is contained in:
@@ -237,7 +237,7 @@ _dl_fini (void)
|
||||
if (__builtin_expect (GLRO(dl_debug_mask)
|
||||
& DL_DEBUG_IMPCALLS, 0))
|
||||
_dl_debug_printf ("\ncalling fini: %s [%lu]\n\n",
|
||||
l->l_name[0] ? l->l_name : rtld_progname,
|
||||
DSO_FILENAME (l->l_name),
|
||||
ns);
|
||||
|
||||
/* First see whether an array is given. */
|
||||
|
||||
Reference in New Issue
Block a user