MCPcopy Create free account
hub / github.com/ajkhoury/ReClassEx / LoadSymbolsForModule

Method LoadSymbolsForModule

ReClass/Symbols.cpp:154–188  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

152}
153
154BOOLEAN Symbols::LoadSymbolsForModule( CString ModulePath, ULONG_PTR ModuleBaseAddress, ULONG SizeOfModule )
155{
156 int idx = -1;
157 CString ModuleName;
158 const TCHAR* szSearchPath = NULL;
159 SymbolReader* reader = NULL;
160 BOOLEAN bSucc = FALSE;
161
162 idx = ModulePath.ReverseFind( '/' );
163 if (idx == -1)
164 idx = ModulePath.ReverseFind( '\\' );
165 ModuleName = ModulePath.Mid( ++idx );
166
167 if (!m_strSearchPath.IsEmpty( ))
168 szSearchPath = m_strSearchPath.GetString( );
169
170 reader = new SymbolReader( );
171
172 //ntdll::RtlEnterCriticalSection( &m_CriticalSection );
173
174 bSucc = reader->LoadFile( ModuleName, ModulePath, ModuleBaseAddress, SizeOfModule, szSearchPath );
175
176 //ntdll::RtlLeaveCriticalSection( &m_CriticalSection );
177
178 if (bSucc)
179 {
180 PrintOut( _T( "[Symbols::LoadSymbolsForModule] Symbols for module %s loaded" ), ModuleName.GetString( ) );
181 m_SymbolAddresses.insert( std::make_pair( ModuleBaseAddress, reader ) );
182 return TRUE;
183 }
184
185 delete reader;
186
187 return FALSE;
188}
189
190BOOLEAN Symbols::LoadSymbolsForPdb( CString PdbPath )
191{

Callers 2

OnAttachButtonMethod · 0.80
SetSelectedMethod · 0.80

Calls 1

LoadFileMethod · 0.45

Tested by

no test coverage detected