Mercurial > touhou
diff pytouhou/formats/exe.py @ 305:5492472963b0
Minor cleanup
author | Thibaut Girka <thib@sitedethib.com> |
---|---|
date | Tue, 13 Mar 2012 18:45:43 +0100 |
parents | 92a6fd2632f1 |
children | 2674c789e0c3 |
line wrap: on
line diff
--- a/pytouhou/formats/exe.py +++ b/pytouhou/formats/exe.py @@ -138,12 +138,8 @@ class SHT(object): pe_file = PEFile(file) data_section = [section for section in pe_file.sections if section.Name.startswith('.data')][0] - text_section = [section for section in pe_file.sections - if section.Name.startswith('.text')][0] data_va = pe_file.image_base + data_section.VirtualAddress data_size = data_section.SizeOfRawData - text_va = pe_file.image_base + text_section.VirtualAddress - text_size = text_section.SizeOfRawData possible_character_records = list(cls.find_character_defs(pe_file)) if not possible_character_records: