Nicolas Geoffray | 28453cf | 2017-08-10 15:30:26 +0100 | [diff] [blame] | 1 | Test for a dex file with an odd size followed by an aligned dex file. |
2 | |||||
3 | The code in classes.dex is: | ||||
4 | |||||
5 | class Main { | ||||
6 | public static void main(String[] args) { | ||||
7 | System.out.println("HelloWorld"); | ||||
8 | } | ||||
9 | } | ||||
10 | |||||
11 | The generated dex file was then manually edited to: | ||||
12 | 1) Add 1 to the size value in the dex header. | ||||
13 | 2) Add 1 byte to the file. | ||||
14 | 3) Change the checksum in the dex header. | ||||
15 | |||||
16 | The code in classes2.dex is: | ||||
17 | |||||
18 | class Foo { | ||||
19 | } |