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

Attempt to invoke interface method 'void com.ryg.dynamicload.DLPlugin.onWindowAttributesChanged(android.view.WindowManager$LayoutParams)' on a null object reference #165

Open
zhenchong opened this issue Oct 12, 2018 · 1 comment

Comments

@zhenchong
Copy link

遇到如下crash请指教,注释掉DLProxyActivity中的onWindowAttributesChanged方法就正常了,有人知道这是为啥吗?
E/AndroidRuntime( 5315): Process: com.ryg.dynamicload.sample.mainhost, PID: 5315
10-12 14:30:42.408 E/AndroidRuntime( 5315): java.lang.RuntimeException: Unable to start activity ComponentInfo{com.ryg.dynamicload.sample.mainhost/com.ryg.dynamicload.DLProxyActivity}: java.lang.NullPointerException: Attempt to invoke interface method 'void com.ryg.dynamicload.DLPlugin.onWindowAttributesChanged(android.view.WindowManager$LayoutParams)' on a null object reference
10-12 14:30:42.408 E/AndroidRuntime( 5315): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2815)
10-12 14:30:42.408 E/AndroidRuntime( 5315): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2893)
10-12 14:30:42.408 E/AndroidRuntime( 5315): at android.app.ActivityThread.-wrap11(Unknown Source:0)
10-12 14:30:42.408 E/AndroidRuntime( 5315): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1616)
10-12 14:30:42.408 E/AndroidRuntime( 5315): at android.os.Handler.dispatchMessage(Handler.java:106)
10-12 14:30:42.408 E/AndroidRuntime( 5315): at android.os.Looper.loop(Looper.java:164)
10-12 14:30:42.408 E/AndroidRuntime( 5315): at android.app.ActivityThread.main(ActivityThread.java:6650)
10-12 14:30:42.408 E/AndroidRuntime( 5315): at java.lang.reflect.Method.invoke(Native Method)
10-12 14:30:42.408 E/AndroidRuntime( 5315): at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:547)
10-12 14:30:42.408 E/AndroidRuntime( 5315): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:818)
10-12 14:30:42.408 E/AndroidRuntime( 5315): Caused by: java.lang.NullPointerException: Attempt to invoke interface method 'void com.ryg.dynamicload.DLPlugin.onWindowAttributesChanged(android.view.WindowManager$LayoutParams)' on a null object reference
10-12 14:30:42.408 E/AndroidRuntime( 5315): at com.ryg.dynamicload.DLProxyActivity.onWindowAttributesChanged(DLProxyActivity.java:155)
10-12 14:30:42.408 E/AndroidRuntime( 5315): at android.view.Window.dispatchWindowAttributesChanged(Window.java:1147)
10-12 14:30:42.408 E/AndroidRuntime( 5315): at com.android.internal.policy.PhoneWindow.dispatchWindowAttributesChanged(PhoneWindow.java:2973)
10-12 14:30:42.408 E/AndroidRuntime( 5315): at android.view.Window.setColorMode(Window.java:1168)
10-12 14:30:42.408 E/AndroidRuntime( 5315): at android.app.Activity.attach(Activity.java:7080)
10-12 14:30:42.408 E/AndroidRuntime( 5315): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2748)
10-12 14:30:42.408 E/AndroidRuntime( 5315): ... 9 more
10-12 14:30:42.413 W/ActivityManager( 1347): Force finishing activity com.ryg.dynamicload.sample.mainhost/com.ryg.dynamicload.DLProxyActivity
10-12 14:30:42.416 W/ActivityManager( 1347): Force finishing activity com.ryg.dynamicload.sample.mainhost/.MainActivity
10-12 14:30:42.421 W/ContextImpl( 1347): Calling a method in the system process without a qualified user: android.app.ContextImpl.bindService:1566 android.content.ContextWrapper.bindService:694 miui.os.DropBoxManager.Bl:361 miui.os.DropBoxManager.Bk:350 miui.os.DropBoxManager.addText:314

@yxwandroid
Copy link

遇到相同的问题 求解

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