实际场景使用手机型号——坚果 R1-Android 8.1.0,点击拍照时出现如下错误详情:
java.lang.RuntimeException: Failure delivering result ResultInfo{who=null, request=1, result=-1, data=Intent { dat=file:///storage/emulated/0/DCIM/Camera/2020_04_01_12_19_23.jpg (has extras) }} to activity {com.ncars.jyds/com.yanzhenjie.album.app.camera.CameraActivity}: java.lang.NullPointerException: Attempt to invoke a virtual method on a null object reference
at android.app.ActivityThread.deliverResults(ActivityThread.java:4774)
at android.app.ActivityThread.handleSendResult(ActivityThread.java:4818)
at android.app.ActivityThread.-wrap20(Unknown Source:0)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1843)
at android.os.Handler.dispatchMessage(Handler.java:106)
at android.os.Looper.loop(Looper.java:167)
at android.app.ActivityThread.main(ActivityThread.java:7145)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:438)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:820)
Caused by: java.lang.NullPointerException: Attempt to invoke a virtual method on a null object reference
at com.ncars.base.utils.b.a(SourceFile:40)
at com.ncars.base.utils.b.i(SourceFile:30)
at com.ncars.jyds.e.k$c$1.eq(SourceFile:112)
at com.ncars.jyds.e.k$c$1.bB(SourceFile:22)
at com.yanzhenjie.album.app.camera.CameraActivity.NB(SourceFile:178)
at com.yanzhenjie.album.app.camera.CameraActivity.onActivityResult(SourceFile:165)
at android.app.Activity.dispatchActivityResult(Activity.java:7569)
at android.app.ActivityThread.deliverResults(ActivityThread.java:4770)
... 9 more
java.lang.NullPointerException: Attempt to invoke a virtual method on a null object reference
at com.ncars.base.utils.b.a(SourceFile:40)
at com.ncars.base.utils.b.i(SourceFile:30)
at com.ncars.jyds.e.k$c$1.eq(SourceFile:112)
at com.ncars.jyds.e.k$c$1.bB(SourceFile:22)
at com.yanzhenjie.album.app.camera.CameraActivity.NB(SourceFile:178)
at com.yanzhenjie.album.app.camera.CameraActivity.onActivityResult(SourceFile:165)
at android.app.Activity.dispatchActivityResult(Activity.java:7569)
at android.app.ActivityThread.deliverResults(ActivityThread.java:4770)
at android.app.ActivityThread.handleSendResult(ActivityThread.java:4818)
at android.app.ActivityThread.-wrap20(Unknown Source:0)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1843)
at android.os.Handler.dispatchMessage(Handler.java:106)
at android.os.Looper.loop(Looper.java:167)
at android.app.ActivityThread.main(ActivityThread.java:7145)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:438)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:820)
实际场景使用手机型号——坚果 R1-Android 8.1.0,点击拍照时出现如下错误详情: java.lang.RuntimeException: Failure delivering result ResultInfo{who=null, request=1, result=-1, data=Intent { dat=file:///storage/emulated/0/DCIM/Camera/2020_04_01_12_19_23.jpg (has extras) }} to activity {com.ncars.jyds/com.yanzhenjie.album.app.camera.CameraActivity}: java.lang.NullPointerException: Attempt to invoke a virtual method on a null object reference at android.app.ActivityThread.deliverResults(ActivityThread.java:4774) at android.app.ActivityThread.handleSendResult(ActivityThread.java:4818) at android.app.ActivityThread.-wrap20(Unknown Source:0) at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1843) at android.os.Handler.dispatchMessage(Handler.java:106) at android.os.Looper.loop(Looper.java:167) at android.app.ActivityThread.main(ActivityThread.java:7145) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:438) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:820) Caused by: java.lang.NullPointerException: Attempt to invoke a virtual method on a null object reference at com.ncars.base.utils.b.a(SourceFile:40) at com.ncars.base.utils.b.i(SourceFile:30) at com.ncars.jyds.e.k$c$1.eq(SourceFile:112) at com.ncars.jyds.e.k$c$1.bB(SourceFile:22) at com.yanzhenjie.album.app.camera.CameraActivity.NB(SourceFile:178) at com.yanzhenjie.album.app.camera.CameraActivity.onActivityResult(SourceFile:165) at android.app.Activity.dispatchActivityResult(Activity.java:7569) at android.app.ActivityThread.deliverResults(ActivityThread.java:4770) ... 9 more java.lang.NullPointerException: Attempt to invoke a virtual method on a null object reference at com.ncars.base.utils.b.a(SourceFile:40) at com.ncars.base.utils.b.i(SourceFile:30) at com.ncars.jyds.e.k$c$1.eq(SourceFile:112) at com.ncars.jyds.e.k$c$1.bB(SourceFile:22) at com.yanzhenjie.album.app.camera.CameraActivity.NB(SourceFile:178) at com.yanzhenjie.album.app.camera.CameraActivity.onActivityResult(SourceFile:165) at android.app.Activity.dispatchActivityResult(Activity.java:7569) at android.app.ActivityThread.deliverResults(ActivityThread.java:4770) at android.app.ActivityThread.handleSendResult(ActivityThread.java:4818) at android.app.ActivityThread.-wrap20(Unknown Source:0) at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1843) at android.os.Handler.dispatchMessage(Handler.java:106) at android.os.Looper.loop(Looper.java:167) at android.app.ActivityThread.main(ActivityThread.java:7145) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:438) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:820)