使用 LanguageUtils 导致的crash 。 将ActivityLifecycleImpl中的 LanguageUtils.applyLanguage(activity); 注释掉之后,就不会爆出这个 crash 了
- AndroidUtilCode 的版本:1.29
- 出现 Bug 的设备型号:GlocalMe S20iQ19
- 设备的 Android 版本:28
@Override
public void onActivityCreated(Activity activity, Bundle savedInstanceState) {
// LanguageUtils.applyLanguage(activity);
setAnimatorsEnabled();
setTopActivity(activity);
}
异常堆栈
2020-09-15 17:24:38.558 27235-27235/com.wws.kimifi E/AndroidRuntime: FATAL EXCEPTION: main
Process: com.wws.kimifi, PID: 27235
java.lang.IllegalArgumentException: Service not registered: IF@f4e9486
at android.app.LoadedApk.forgetServiceDispatcher(LoadedApk.java:1562)
at android.app.ContextImpl.unbindService(ContextImpl.java:1692)
at android.content.ContextWrapper.unbindService(ContextWrapper.java:717)
at android.content.ContextWrapper.unbindService(ContextWrapper.java:717)
at IE.handleMessage(PG:63)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:197)
at android.app.ActivityThread.main(ActivityThread.java:6764)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:493)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:858)