Skip to content
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

"Can't find immediate dominator for block B" in latest Gmail APK #451

Closed
guessit-dev opened this issue Feb 21, 2019 · 2 comments
Closed

Comments

@guessit-dev
Copy link

guessit-dev commented Feb 21, 2019

There are > 1000 errors while decompiling.

Most seem to be of the following signature:

ERROR - JadxRuntimeException in pass: BlockProcessor in method: acqf.get():V, dex: classes.dex
jadx.core.utils.exceptions.JadxRuntimeException: Can't find immediate dominator for block B:34:0x006a in {4, 5, 9, 19, 20, 24, 26, 29, 31, 33} preds:[]
at jadx.core.dex.visitors.blocksmaker.BlockProcessor.computeDominators(BlockProcessor.java:242)
at jadx.core.dex.visitors.blocksmaker.BlockProcessor.processBlocksTree(BlockProcessor.java:52)
at jadx.core.dex.visitors.blocksmaker.BlockProcessor.visit(BlockProcessor.java:42)
at jadx.core.dex.visitors.DepthTraversal.visit(DepthTraversal.java:27)
at jadx.core.dex.visitors.DepthTraversal.lambda$visit$1(DepthTraversal.java:14)
at java.util.ArrayList.forEach(ArrayList.java:1257)
at jadx.core.dex.visitors.DepthTraversal.visit(DepthTraversal.java:14)
at jadx.core.ProcessClass.process(ProcessClass.java:32)
at jadx.core.ProcessClass.lambda$processDependencies$0(ProcessClass.java:51)
at java.lang.Iterable.forEach(Iterable.java:75)
at jadx.core.ProcessClass.processDependencies(ProcessClass.java:51)
at jadx.core.ProcessClass.process(ProcessClass.java:37)
at jadx.api.JadxDecompiler.processClass(JadxDecompiler.java:292)
at jadx.api.JavaClass.decompile(JavaClass.java:62)
at jadx.api.JadxDecompiler.lambda$appendSourcesSave$0(JadxDecompiler.java:200)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)

jadx version: 0.9.0

APK:
https://www.apkmirror.com/apk/google-inc/gmail/gmail-9-1-13-233495724-release-release/gmail-9-1-13-233495724-release-android-apk-download/

@skylot
Copy link
Owner

skylot commented Feb 21, 2019

@guessit-dev thanks!
This is a nice example of dead and incorrect code: return-void instruction (method must return an object) after throw:

...
    return-object v0
    .line 1
    :cond_7
    new-instance v0, Ljava/lang/InterruptedException;
    invoke-direct {v0}, Ljava/lang/InterruptedException;-><init>()V
    throw v0
    return-void
.end method

I will remove such unreachable code and leave a notice in methods comment.

skylot added a commit that referenced this issue Feb 21, 2019
@skylot
Copy link
Owner

skylot commented Feb 21, 2019

@guessit-dev I made a fix, please check latest unstable build.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants