alibaba / alibaba/AndFix

android 2.3 版本运行完patch后崩溃

Open
#62 3 comments 0 reactions 0 assignees View on GitHub
Dominant language
C++
Stars
7k
Forks
1.6k
PR merge metrics
No merged PRs in 30d

Description

在os 2.3 版本的手机上兼容得不好,我测试了三部 2.3 手机,都能够运行patch,但运行结束后都会出现异常,java.lang.RuntimeException: Unable to start activity ComponentInfo{com.euler.andfix/com.euler.andfix.MainActivity}: java.lang.NullPointerException: null result when primitive expected。接着程序就挂掉了。我看了下jni文件夹下的dalvik_method_replace.cpp,应该是returnType = dvmGetBoxedReturnType_fnPtr(method);这里面的 returnType 返回的是null, 而我们期待它返回的是 PRIM_VOID,所以挂掉了。为什么会这样?有什么解决办法吗?

Contributor guide

No contributing guide indexed for this repository

Research direction

Start with jni/dalvik_method_replace.cpp and reproduce the crash on an Android 2.3 device after a patch completes. Inspect why dvmGetBoxedReturnType_fnPtr(method) returns null instead of PRIM_VOID, then verify that the patched application finishes without the reported NullPointerException.

Written by the indexing model from the issue text.

Assessment

Tech stack
android, cpp
Domain
mobile-dev
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.