0

i'm building an android app , when i'm testing it on an emulator ,it's running well but for a device it stops ( minSdkVersion 17 targetSdkVersion 26 )

12-11 20:56:22.241 10670-10702/? W/PushLog2616: [ReceiverDispatcher-409]init bastet error(android/null:-1)
                                                java.lang.NullPointerException: Attempt to invoke interface method 'int com.huawei.android.bastet.IBastetManager.prepareHeartbeatProxy(int, com.huawei.android.bastet.IBastetListener)' on a null object reference
                                                    at com.huawei.android.bastet.HwBastet.prepareHeartbeatProxy(HwBastet.java:365)
                                                    at com.huawei.android.bastet.HwBastet.<init>(HwBastet.java:107)
                                                    at com.huawei.android.pushagent.utils.bastet.PushBastet.bW(Unknown Source)
                                                    at com.huawei.android.pushagent.utils.bastet.PushBastet.bV(Unknown Source)
                                                    at w.bl(Unknown Source)
                                                    at com.huawei.android.pushagent.model.channel.ChannelMgr.c(Unknown Source)
                                                    at af.onReceive(Unknown Source)
                                                    at e.run(Unknown Source)
                                                    at android.os.Handler.handleCallback(Handler.java:743)
                                                    at android.os.Handler.dispatchMessage(Handler.java:95)
                                                    at android.os.Looper.loop(Looper.java:150)
                                                    at c.run(Unknown Source)
12-11 20:56:22.241 1297-3038/? I/ActivityManager: new Process app=ProcessRe
Rami bellili
  • 67
  • 1
  • 2
  • 12
  • post the code to understand,. from this error log it seems some bastetManager is null – Aalap Patel Dec 11 '17 at 21:29
  • 2
    Possible duplicate of [What is a NullPointerException, and how do I fix it?](https://stackoverflow.com/questions/218384/what-is-a-nullpointerexception-and-how-do-i-fix-it) – takendarkk Dec 11 '17 at 21:29
  • i'm using the JSONParser class and AsyncTask for accessing to a service , in emulator i get the right result but in device when cliking to the button that calls the webservice , the app stops – Rami bellili Dec 11 '17 at 21:50

0 Answers0