-
Notifications
You must be signed in to change notification settings - Fork 406
Open
Description
如图,这是我的Application和Android.mk的配置。
这是加固之后反编译后的结果
com.android.p000native.MainApplication
是通过命令行--custom-loader com.android.native.MainApplication
指定得到的。
可以看到LitePal.initialize(getApplicationContext());
这一句是在的。
但是好像代码好像实际上没有执行到这里,是不是因为Application改掉的原因?
相关Logcat:
FATAL EXCEPTION: main
Process: xxxxxxxxxxxxxxxxxxxxxxxx, PID: 8635
org.litepal.exceptions.GlobalException: Application context is null. Maybe you neither configured your application name with "org.litepal.LitePalApplication" in your AndroidManifest.xml, nor called LitePal.initialize(Context) method.
at org.litepal.LitePalApplication.getContext(SourceFile:9)
at org.litepal.util.BaseUtility.isLitePalXMLExists(SourceFile:2)
at org.litepal.parser.LitePalAttr.loadLitePalXMLConfiguration(SourceFile:1)
at org.litepal.parser.LitePalAttr.checkSelfValid(SourceFile:8)
at org.litepal.tablemanager.Connector.buildConnection(SourceFile:5)
at org.litepal.tablemanager.Connector.getWritableDatabase(SourceFile:4)
at org.litepal.tablemanager.Connector.getDatabase(SourceFile:1)
at org.litepal.FluentQuery.find(SourceFile:3)
at org.litepal.FluentQuery.find(SourceFile:1)
at m2.c.A(SourceFile:432)
at b5.f.onClick(SourceFile:67)
at android.view.View.performClick(View.java:7750)
at android.view.View.performClickInternal(View.java:7727)
at android.view.View.access$3700(View.java:861)
at android.view.View$PerformClick.run(View.java:29133)
at android.os.Handler.handleCallback(Handler.java:938)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loopOnce(Looper.java:210)
at android.os.Looper.loop(Looper.java:299)
at android.app.ActivityThread.main(ActivityThread.java:8103)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:556)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1045)
请作者帮忙看看!
Metadata
Metadata
Assignees
Labels
No labels