protected BinaryParser OpenDirectory(PEDataDirectory dir) { PESection section = FindSectionByRva(dir.VirtualAddress); if (section == null) { InvalidPEFileException.ThrowInvalidRva(); } uint index = (section.PointerToRawData + (dir.VirtualAddress - section.VirtualAdress)); uint count = (dir.Size); Stream imageStream = OpenImage(index); return(new BinaryParser(imageStream, index)); }
protected BinaryParser OpenDirectory(PEDataDirectory dir) { PESection section = FindSectionByRva(dir.VirtualAddress); if (section == null) { InvalidPEFileException.ThrowInvalidRva(); } uint index = (section.PointerToRawData + (dir.VirtualAddress - section.VirtualAdress)); uint count = (dir.Size); Stream imageStream = OpenImage(index); return new BinaryParser(imageStream, index); }