| 818 | } |
| 819 | |
| 820 | std::wstring CProcessInlineHookTable::GetSingleHookInfo(InlineHookInfo& info) { |
| 821 | CString text; |
| 822 | CString s; |
| 823 | |
| 824 | s = info.Name.c_str(); |
| 825 | s += L"\t"; |
| 826 | text += s; |
| 827 | |
| 828 | s = TypeToString(info.Type); |
| 829 | s += L"\t"; |
| 830 | text += s; |
| 831 | |
| 832 | auto& symbols = SymbolManager::Get(); |
| 833 | DWORD64 offset = 0; |
| 834 | auto symbol = symbols.GetSymbolFromAddress(m_Pid, info.Address, &offset); |
| 835 | if (symbol) { |
| 836 | CStringA m; |
| 837 | auto sym = symbol->GetSymbolInfo(); |
| 838 | m.Format("%s!%s+0x%X", symbol->ModuleInfo.ModuleName, sym->Name, (DWORD)offset); |
| 839 | std::string details = m.GetString(); |
| 840 | std::wstring wdetails = Helpers::StringToWstring(details); |
| 841 | s.Format(L"0x%p (%s)", info.Address, wdetails.c_str()); |
| 842 | } |
| 843 | else |
| 844 | s.Format(L"0x%p", info.Address); |
| 845 | s += L"\t"; |
| 846 | text += s; |
| 847 | |
| 848 | s.Format(L"0x%p", info.TargetAddress); |
| 849 | s += L"\t"; |
| 850 | text += s; |
| 851 | |
| 852 | s = info.TargetModule.c_str(); |
| 853 | s += L"\t"; |
| 854 | text += s; |
| 855 | |
| 856 | text += L"\r\n"; |
| 857 | |
| 858 | return text.GetString(); |
| 859 | } |
nothing calls this directly
no test coverage detected