Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix dex module inconsistencies (#2069)
* fix signature and magic strings in dex module Several bytestring values in the dex module were not set properly, and were cut short due to the presence of a nul byte. This happened on: - all the dex.DEX_FILE_MAGIC_* constants, which were cut short by one byte (the last one is the nul byte). - the magic and signature field in the "header" object of the module. For all of those, the size is fixed and known, so use the right length and do not cut it short if a nul byte is present. * fix declared fields in the dex module There was some mismatch between the declared fields and the ones filled by the module: - `dex.field[*].static` and `dex.field[*].instance` were defined, but not declared, making their use impossible. They are now properly declared. - several fields in `dex.method[*].code_item` were declared but never defined: `padding`, `tries` and `handlers`. Those are removed since they couldn't have been used.
- Loading branch information