Update __init__.py to fix typing of self._data to bytes

This commit is contained in:
Nicolas Kruse 2025-07-23 23:01:41 +02:00 committed by GitHub
parent 77f8b5ed44
commit c6682effc7
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 1 deletions

View File

@ -371,7 +371,7 @@ class elf_file:
data: binary ELF data data: binary ELF data
""" """
assert isinstance(data, (bytes, bytearray)), 'Binary ELF data must be provided as bytes or bytearray.' assert isinstance(data, (bytes, bytearray)), 'Binary ELF data must be provided as bytes or bytearray.'
self._data = data self._data = bytes(data)
# Defaults required for function _read_int_from_elf_field # Defaults required for function _read_int_from_elf_field
self.bit_width = 32 self.bit_width = 32