| 6854 | } |
| 6855 | |
| 6856 | bool COFF::LoadModuleImage(const StringImpl& imagePath) |
| 6857 | { |
| 6858 | if (!mDebugger->IsMiniDumpDebugger()) |
| 6859 | return false; |
| 6860 | |
| 6861 | auto miniDumpDebugger = (MiniDumpDebugger*)mDebugger; |
| 6862 | |
| 6863 | if (!imagePath.IsEmpty()) |
| 6864 | { |
| 6865 | MappedFile* mappedFile = miniDumpDebugger->MapModule(this, imagePath); |
| 6866 | mMappedImageFile = mappedFile; |
| 6867 | |
| 6868 | if (mappedFile != NULL) |
| 6869 | { |
| 6870 | MemStream memStream(mappedFile->mData, mappedFile->mFileSize, false); |
| 6871 | ReadCOFF(&memStream, DbgModuleKind_Module); |
| 6872 | |
| 6873 | mOrigImageData = new DbgModuleMemoryCache(mImageBase, mImageSize); |
| 6874 | } |
| 6875 | } |
| 6876 | |
| 6877 | if (mOrigImageData == NULL) // Failed? |
| 6878 | { |
| 6879 | mLoadState = DbgModuleLoadState_Failed; |
| 6880 | return false; |
| 6881 | } |
| 6882 | |
| 6883 | return true; |
| 6884 | } |
| 6885 | |
| 6886 | bool COFF::RequestImage() |
| 6887 | { |
no test coverage detected