java.lang.RuntimeException: Failure delivering result ResultInfo{who=null, request=1007, result=-1, data=Intent { typ=image/* }} to activity : java.lang.NullPointerException
at android.app.ActivityThread.deliverResults(ActivityThread.java:3361)
at android.app.ActivityThread.handleSendResult(ActivityThread.java:3404)
at android.app.ActivityThread.access$1300(ActivityThread.java:139)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1248)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:136)
at android.app.ActivityThread.main(ActivityThread.java:5011)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:832)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:648)
at dalvik.system.NativeStart.main(Native Method)
Caused by: java.lang.NullPointerException
at com.jph.takephoto.uitl.TImageFiles.getMimeType(TImageFiles.java:122)
at com.jph.takephoto.app.TakePhotoImpl.onCrop(TakePhotoImpl.java:267)
at com.jph.takephoto.app.TakePhotoImpl.onActivityResult(TakePhotoImpl.java:110)
at android.app.Activity.dispatchActivityResult(Activity.java:5433)
at android.app.ActivityThread.deliverResults(ActivityThread.java:3357)
... 11 more
java.lang.NullPointerException
at com.jph.takephoto.uitl.TImageFiles.getMimeType(TImageFiles.java:122)
at com.jph.takephoto.app.TakePhotoImpl.onCrop(TakePhotoImpl.java:267)
at com.jph.takephoto.app.TakePhotoImpl.onActivityResult(TakePhotoImpl.java:110)
at android.app.Activity.dispatchActivityResult(Activity.java:5433)
at android.app.ActivityThread.deliverResults(ActivityThread.java:3357)
at android.app.ActivityThread.handleSendResult(ActivityThread.java:3404)
at android.app.ActivityThread.access$1300(ActivityThread.java:139)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1248)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:136)
at android.app.ActivityThread.main(ActivityThread.java:5011)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:832)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:648)
at dalvik.system.NativeStart.main(Native Method)
你好,我在使用 v3.0.4 的时候,出现了空指针的崩溃。详细堆栈信息如下:
java.lang.RuntimeException: Failure delivering result ResultInfo{who=null, request=1007, result=-1, data=Intent { typ=image/* }} to activity : java.lang.NullPointerException at android.app.ActivityThread.deliverResults(ActivityThread.java:3361) at android.app.ActivityThread.handleSendResult(ActivityThread.java:3404) at android.app.ActivityThread.access$1300(ActivityThread.java:139) at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1248) at android.os.Handler.dispatchMessage(Handler.java:102) at android.os.Looper.loop(Looper.java:136) at android.app.ActivityThread.main(ActivityThread.java:5011) at java.lang.reflect.Method.invokeNative(Native Method) at java.lang.reflect.Method.invoke(Method.java:515) at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:832) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:648) at dalvik.system.NativeStart.main(Native Method) Caused by: java.lang.NullPointerException at com.jph.takephoto.uitl.TImageFiles.getMimeType(TImageFiles.java:122) at com.jph.takephoto.app.TakePhotoImpl.onCrop(TakePhotoImpl.java:267) at com.jph.takephoto.app.TakePhotoImpl.onActivityResult(TakePhotoImpl.java:110) at android.app.Activity.dispatchActivityResult(Activity.java:5433) at android.app.ActivityThread.deliverResults(ActivityThread.java:3357) ... 11 more java.lang.NullPointerException at com.jph.takephoto.uitl.TImageFiles.getMimeType(TImageFiles.java:122) at com.jph.takephoto.app.TakePhotoImpl.onCrop(TakePhotoImpl.java:267) at com.jph.takephoto.app.TakePhotoImpl.onActivityResult(TakePhotoImpl.java:110) at android.app.Activity.dispatchActivityResult(Activity.java:5433) at android.app.ActivityThread.deliverResults(ActivityThread.java:3357) at android.app.ActivityThread.handleSendResult(ActivityThread.java:3404) at android.app.ActivityThread.access$1300(ActivityThread.java:139) at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1248) at android.os.Handler.dispatchMessage(Handler.java:102) at android.os.Looper.loop(Looper.java:136) at android.app.ActivityThread.main(ActivityThread.java:5011) at java.lang.reflect.Method.invokeNative(Native Method) at java.lang.reflect.Method.invoke(Method.java:515) at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:832) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:648) at dalvik.system.NativeStart.main(Native Method)
更新日志上没看出来是否修复,麻烦你看一下。 谢谢!