зеркало из https://github.com/mozilla/pjs.git
Support demangling again by working around crash bug in demangle library
This commit is contained in:
Родитель
8464de5c3c
Коммит
7d27a06de1
|
@ -69,10 +69,12 @@ void leaky::ReadSymbols(const char *aFileName, u_long aBaseAddress)
|
|||
|
||||
// if ((syminfo.type == 'T') || (syminfo.type == 't')) {
|
||||
const char* nm = bfd_asymbol_name(sym);
|
||||
if (nm) {
|
||||
// char* dnm = cplus_demangle(nm, 1);
|
||||
// sp->name = dnm ? dnm : strdup(nm);
|
||||
sp->Init(nm, syminfo.value + aBaseAddress);
|
||||
if (nm && nm[0]) {
|
||||
char* dnm = NULL;
|
||||
if (strncmp("__thunk", nm, 7)) {
|
||||
dnm = cplus_demangle(nm, 1);
|
||||
}
|
||||
sp->Init(dnm ? dnm : nm, syminfo.value + aBaseAddress);
|
||||
sp++;
|
||||
if (sp >= lastSymbol) {
|
||||
long n = numExternalSymbols + 10000;
|
||||
|
|
Загрузка…
Ссылка в новой задаче