In my c++ applicatoin I have the virtual addresses of functions and I want to get their mangled names.
right now I can get only the unmangled name by using the winapi SymFromAddr
function.
is there a way to get the mangled names also ?
Asked
Active
Viewed 403 times
3

max
- 93
- 5
1 Answers
6
Use SymSetOptions(). You want to turn off the SYMOPT_UNDNAME
option to see the mangled name.
So, roughly:
DWORD options = SymGetOptions();
SymSetOptions(options & ~SYMOPT_UNDNAME);
if (SymFromAddr(hProcess, dwAddress, &dwDisplacement, pSymbol))
{
// etc...
}
SymSetOptions(options);

Hans Passant
- 922,412
- 146
- 1,693
- 2,536
-
2Thanks , this worked but I also had to turn on the SYMOPT_PUBLICS_ONLY flag – max Nov 19 '14 at 12:41