onepf / OpenIAB

Open In-App Billing for Google Play, SlideMe, Amazon Store, Nokia Store, Samsung Apps, Yandex.Store, Appland, Aptoide, AppMall and Fortumo.
http://onepf.org/openiab/
Apache License 2.0
475 stars 171 forks source link

NPE in IabHelper in v. 0.9.8.7 #535

Open nkuznetsow opened 7 years ago

nkuznetsow commented 7 years ago

I use OpenIAB v. 0.9.8.7 from this https://mvnrepository.com/artifact/org.onepf/openiab/0.9.8.7 In Fabric I have seen many crashes like this:

Fatal Exception: java.lang.NullPointerException
       at org.onepf.oms.appstore.googleUtils.IabHelper$1.onServiceConnected(IabHelper.java:248)
       at android.app.LoadedApk$ServiceDispatcher.doConnected(LoadedApk.java:1097)
       at android.app.LoadedApk$ServiceDispatcher$RunConnection.run(LoadedApk.java:1114)
       at android.os.Handler.handleCallback(Handler.java:615)
       at android.os.Handler.dispatchMessage(Handler.java:92)
       at android.os.Looper.loop(Looper.java:153)
       at android.app.ActivityThread.main(ActivityThread.java:5070)
       at java.lang.reflect.Method.invokeNative(Method.java)
       at java.lang.reflect.Method.invoke(Method.java:511)
       at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:790)
       at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:557)
       at dalvik.system.NativeStart.main(NativeStart.java)

The last version of IabHelper class in master branch I unable to find onServiceConnected method body on line 248. I think, that this class was rewrote. If it true, please, release the new version of the lib to fix this crach.