Do not call __pthread_cxa_finalize with invalid struct dl_phdr_info.

Reported and tested by:	Fabian Keil <freebsd-listen fabiankeil de>
MFC after:	17 days
This commit is contained in:
Konstantin Belousov 2010-08-27 19:57:17 +00:00
parent b47f51b4a0
commit 3eaca8526c

View File

@ -200,6 +200,6 @@ __cxa_finalize(void *dso)
if (dso == NULL)
_MUTEX_DESTROY(&atexit_mutex);
if (&__pthread_cxa_finalize != NULL)
if (has_phdr && &__pthread_cxa_finalize != NULL)
__pthread_cxa_finalize(&phdr_info);
}