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

NullPointerException in ShellImpl.testCmd #4

Closed
hemisphire opened this issue Mar 5, 2018 · 0 comments
Closed

NullPointerException in ShellImpl.testCmd #4

hemisphire opened this issue Mar 5, 2018 · 0 comments

Comments

@hemisphire
Copy link

Looks like testCmd doesn't check for a non null result returned from fastCmd before using split()

FATAL EXCEPTION: main
Process: com.topjohnwu.magisk, PID: 23379
java.lang.ExceptionInInitializerError
at com.topjohnwu.magisk.database.SuDatabaseHelper.openDatabase(Unknown Source)
at com.topjohnwu.magisk.database.SuDatabaseHelper.(Unknown Source)
at com.topjohnwu.magisk.database.SuDatabaseHelper.getInstance(Unknown Source)
at com.topjohnwu.magisk.MagiskManager.onCreate(Unknown Source)
at android.app.Instrumentation.callApplicationOnCreate(Instrumentation.java:1036)
at android.app.ActivityThread.handleBindApplication(ActivityThread.java:6321)
at android.app.ActivityThread.access$1800(ActivityThread.java:222)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1861)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:158)
at android.app.ActivityThread.main(ActivityThread.java:7229)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
Caused by: java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.String[] java.lang.String.split(java.lang.String)' on a null object reference
at com.topjohnwu.superuser.internal.ShellImpl.testCmd(Unknown Source)
at com.topjohnwu.superuser.io.SuFile.testShell(Unknown Source)
at com.topjohnwu.superuser.io.SuFile.(Unknown Source)
at com.topjohnwu.magisk.utils.Const.(Unknown Source)
at com.topjohnwu.magisk.database.SuDatabaseHelper.openDatabase(Unknown Source) 
at com.topjohnwu.magisk.database.SuDatabaseHelper.(Unknown Source) 
at com.topjohnwu.magisk.database.SuDatabaseHelper.getInstance(Unknown Source) 
at com.topjohnwu.magisk.MagiskManager.onCreate(Unknown Source) 
at android.app.Instrumentation.callApplicationOnCreate(Instrumentation.java:1036) 
at android.app.ActivityThread.handleBindApplication(ActivityThread.java:6321) 
at android.app.ActivityThread.access$1800(ActivityThread.java:222) 
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1861) 
at android.os.Handler.dispatchMessage(Handler.java:102) 
at android.os.Looper.loop(Looper.java:158) 
at android.app.ActivityThread.main(ActivityThread.java:7229) 
at java.lang.reflect.Method.invoke(Native Method) 
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230) 
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120) 

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