Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 12 additions & 17 deletions src/coreclr/debug/daccess/daccess.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6378,27 +6378,22 @@ ClrDataAccess::GetMetaDataFileInfoFromPEFile(PEAssembly *pPEAssembly,
SUPPORTS_DAC_HOST_ONLY;
PEImage *mdImage = NULL;
PEImageLayout *layout = NULL;
IMAGE_DATA_DIRECTORY *pDir = NULL;
COUNT_T uniPathChars = 0;

if (pDir == NULL || pDir->Size == 0)
mdImage = pPEAssembly->GetPEImage();
if (mdImage != NULL)
{
mdImage = pPEAssembly->GetPEImage();
if (mdImage != NULL)
{
layout = mdImage->GetLoadedLayout();
pDir = &layout->GetCorHeader()->MetaData;
layout = mdImage->GetLoadedLayout();

// In IL image case, we do not have any hint to IL metadata since it is stored
// in the corheader.
//
dwRvaHint = 0;
dwDataSize = pDir->Size;
}
else
{
return false;
}
// In IL image case, we do not have any hint to IL metadata since it is stored
// in the corheader.
//
dwRvaHint = 0;
dwDataSize = layout->GetCorHeader()->MetaData.Size;
}
else
{
return false;
}

// Do not fail if path can not be read. Triage dumps don't have paths and we want to fallback
Expand Down
Loading