Actually IabHelper contains method to handle it
mServiceConn = new ServiceConnection() {
@Override
public void onServiceDisconnected(ComponentName name) {
logDebug("Billing service disconnected.");
mService = null;
}
@Override
public void onServiceConnected(ComponentName name, IBinder service) {
logDebug("Billing service connected.");
mService = getServiceFromBinder(service);
componentName = name;
String packageName = mContext.getPackageName();
try {
...
and inside it mService it set to null.
But mService is a widely used field. There are several async methods that use
mService. And there is no synchronization, no null-checking.
Could you please explain why it was made so?
I have this question due to a lot of npe reports from my users. I'm not sure
that mService became null after disconnect but there is a possibility of it.
Original issue reported on code.google.com by Anastasi...@gmail.com on 16 Jan 2014 at 9:57
Original issue reported on code.google.com by
Anastasi...@gmail.com
on 16 Jan 2014 at 9:57