-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Add MappedByteBuffer support for DexBackedDexFile. #744
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
dexlib2/src/main/java/org/jf/dexlib2/dexbacked/DexBackedDexFile.java
Outdated
Show resolved
Hide resolved
| this(opcodes, buf, 0, true); | ||
| } | ||
|
|
||
| public DexBackedDexFile(@Nullable Opcodes opcodes, @Nonnull MappedDexBuffer buf) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think this constructor is needed now?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done. Thanks
| @@ -0,0 +1,104 @@ | |||
| package org.jf.dexlib2.dexbacked; | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As per my last comments, I don't think class needs to be submitted to the smali repo
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done. Thanks
| * @param offset The offset within the buffer to the beginning of the dex header | ||
| * @return True if the magic value is valid | ||
| */ | ||
| public static boolean verifyMagic(MappedByteBuffer buf, int offset) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think any of the changes in this file are needed any longer?
|
Thanks, I squashed the commits, removed some remaining unneeded changes, and reworded the commit message a bit to reflect the recent changes. Committed as b7a1052 |
To let DexBackedDexFile be able to read in DEX file using MappedByteBuffer.