mirror of https://github.com/Nonannet/pelfy.git
Field name fixed in elt_symbol.read_data()
This commit is contained in:
parent
d4c68c8e42
commit
1762c8c435
|
@ -74,7 +74,7 @@ class elf_symbol():
|
||||||
"""
|
"""
|
||||||
assert self.section, 'This symbol is not associated to a data section'
|
assert self.section, 'This symbol is not associated to a data section'
|
||||||
if self.section.type == 'SHT_NOBITS':
|
if self.section.type == 'SHT_NOBITS':
|
||||||
return b'\x00' * self['sh_size']
|
return b'\x00' * self['st_size']
|
||||||
else:
|
else:
|
||||||
offset = self.section['sh_offset'] + self['st_value']
|
offset = self.section['sh_offset'] + self['st_value']
|
||||||
return self.file.read_bytes(offset, self['st_size'])
|
return self.file.read_bytes(offset, self['st_size'])
|
||||||
|
|
Loading…
Reference in New Issue