具体报错情况如下
Process: com.tencent.wxpayface, PID: 19952
java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.String java.lang.Object.toString()' on a null object reference
at android.os.Parcel.readException(Parcel.java:1698)
at android.os.Parcel.readException(Parcel.java:1645)
at com.tencent.wxpayface.c$a$a.a(SourceFile:81)
at com.tencent.wxpayface.connection.FaceConnectService.h(SourceFile:1379)
at com.tencent.wxpayface.connection.FaceConnectService.b(SourceFile:92)
at com.tencent.wxpayface.connection.FaceConnectService$1.onReceive(SourceFile:305)
at android.support.v4.content.c.a(SourceFile:311)
at android.support.v4.content.c.a(SourceFile:47)
at android.support.v4.content.c$1.handleMessage(SourceFile:120)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:154)
at android.app.ActivityThread.main(ActivityThread.java:6137)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:889)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:779)
请问一下具体是因为什么原因
你好 请问你的问题解决了吗 我也碰到了一样的问题
商户按照demo检查一下,这个是非空判断没处理好.按照描述,应该是在getWxpayfaceCode这个接口
WxPayFace.getInstance().getWxpayfaceUserInfo(map, new IWxPayfaceCallback() {
@Override
public void response(final Map info) throws RemoteException {
if (info == null) {
showErrorMsg("人脸支付不可用,请更换其他支付方式");
return;
} else {
final String openId = (String) info.get("openid");
// String sub_openId = (String) info.get("sub_openid");
NickName = info.get("nickname").toString(); // 微信昵称
final String authinfo=(String) map.get("authinfo");
authinfo_main=(String) map.get("authinfo");
if(authinfo!=null && openId!=null)
runOnUiThread(new Runnable() {
@Override
public void run() {
WalletFacePayUtil.stopFaceRecognize( authinfo);
WalletFacePayUtil.getLR_FacePay(openId,mContext,mSharedPreferencesUtils,authinfo);
}
});
}
return;
}
});
报错信息显示是你们提供的SDK没做判空处理,在用户关掉验证的时候没做判空处理,可能需要你们修复下这个bug。
~