【问题标题】:App is crashing after integrating with Mopub与 Mopub 集成后应用程序崩溃
【发布时间】:2017-02-16 11:45:35
【问题描述】:

我们已与 Mopub 集成以进行广告集成。 该应用程序在minify = false 下运行良好。 但是,使用minify = true,应用程序正在崩溃。我们已在此链接中提到的 out 文件中添加了所有 proguard 规则:https://github.com/mopub/mopub-android-sdk/blob/master/mopub-sample/proguard.cfg

日志:

    03-12 17:00:04.791 16874-16874/in.playsimple.word_up I/Tapjoy: The session ended
03-12 17:00:05.140 16874-17001/in.playsimple.word_up E/Surface: getSlotFromBufferLocked: unknown buffer: 0xb8523b20
03-12 17:00:05.211 16874-16874/in.playsimple.word_up E/ActivityThread: Activity org.cocos2dx.javascript.AppActivity has leaked IntentReceiver com.mopub.mobileads.au@dca7bd8 that was originally registered here. Are you missing a call to unregisterReceiver()?
                                                                       android.app.IntentReceiverLeaked: Activity org.cocos2dx.javascript.AppActivity has leaked IntentReceiver com.mopub.mobileads.au@dca7bd8 that was originally registered here. Are you missing a call to unregisterReceiver()?
                                                                           at android.app.LoadedApk$ReceiverDispatcher.<init>(LoadedApk.java:918)
                                                                           at android.app.LoadedApk.getReceiverDispatcher(LoadedApk.java:719)
                                                                           at android.app.ContextImpl.registerReceiverInternal(ContextImpl.java:1172)
                                                                           at android.app.ContextImpl.registerReceiver(ContextImpl.java:1152)
                                                                           at android.app.ContextImpl.registerReceiver(ContextImpl.java:1146)
                                                                           at android.content.ContextWrapper.registerReceiver(ContextWrapper.java:554)
                                                                           at com.mopub.mobileads.MoPubView.a(MoPubView.java:110)
                                                                           at com.mopub.mobileads.MoPubView.<init>(MoPubView.java:88)
                                                                           at com.mopub.mobileads.MoPubView.<init>(MoPubView.java:54)
                                                                           at com.mopub.mobileads.MoPubInterstitial$MoPubInterstitialView.<init>(MoPubInterstitial.java:397)
                                                                           at com.mopub.mobileads.MoPubInterstitial.<init>(MoPubInterstitial.java:71)
                                                                           at in.playsimple.word_up.Interstitial$2.run(Interstitial.java:116)
                                                                           at android.os.Handler.handleCallback(Handler.java:746)
                                                                           at android.os.Handler.dispatchMessage(Handler.java:95)
                                                                           at android.os.Looper.loop(Looper.java:148)
                                                                           at android.app.ActivityThread.main(ActivityThread.java:5443)
                                                                           at java.lang.reflect.Method.invoke(Native Method)
                                                                           at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:728)
                                                                           at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:618)
03-12 17:00:05.217 16874-16925/in.playsimple.word_up D/WordTrek: pingworking = true
03-12 17:00:05.217 16874-16925/in.playsimple.word_up D/WordTrek: Downloading file :: https://playsimple.co/misc_web_server/wordtrek/dictionary_eowl.csv.gz
03-12 17:00:05.218 16874-16925/in.playsimple.word_up I/WordTrek: Downloading file = dictionary_eowl.csv.gz
03-12 17:00:05.218 16874-16925/in.playsimple.word_up D/WordTrek: pingworking = true
03-12 17:00:05.235 16874-16874/in.playsimple.word_up E/ActivityThread: Activity org.cocos2dx.javascript.AppActivity has leaked ServiceConnection android.speech.tts.TextToSpeech$Connection@df3ec64 that was originally bound here
                                                                       android.app.ServiceConnectionLeaked: Activity org.cocos2dx.javascript.AppActivity has leaked ServiceConnection android.speech.tts.TextToSpeech$Connection@df3ec64 that was originally bound here
                                                                           at android.app.LoadedApk$ServiceDispatcher.<init>(LoadedApk.java:1092)
                                                                           at android.app.LoadedApk.getServiceDispatcher(LoadedApk.java:986)
                                                                           at android.app.ContextImpl.bindServiceCommon(ContextImpl.java:1303)
                                                                           at android.app.ContextImpl.bindService(ContextImpl.java:1286)
                                                                           at android.content.ContextWrapper.bindService(ContextWrapper.java:604)
                                                                           at android.speech.tts.TextToSpeech.connectToEngine(TextToSpeech.java:800)
                                                                           at android.speech.tts.TextToSpeech.initTts(TextToSpeech.java:770)
                                                                           at android.speech.tts.TextToSpeech.<init>(TextToSpeech.java:723)
                                                                           at android.speech.tts.TextToSpeech.<init>(TextToSpeech.java:702)
                                                                           at android.speech.tts.TextToSpeech.<init>(TextToSpeech.java:686)
                                                                           at org.cocos2dx.javascript.AppActivity.initTextToSpeech_aroundBody10(AppActivity.java:709)
                                                                           at org.cocos2dx.javascript.AppActivity$AjcClosure11.run(AppActivity.java:1)
                                                                           at org.a.b.b.c.c(JoinPointImpl.java:149)
                                                                           at c.a.a.a.a(Hugo.java:39)
                                                                           at org.cocos2dx.javascript.AppActivity.initTextToSpeech(AppActivity.java:709)
                                                                           at org.cocos2dx.javascript.AppActivity.setup_aroundBody8(AppActivity.java:701)
                                                                           at org.cocos2dx.javascript.AppActivity$AjcClosure9.run(AppActivity.java:1)
                                                                           at org.a.b.b.c.c(JoinPointImpl.java:149)
                                                                           at c.a.a.a.a(Hugo.java:39)
                                                                           at org.cocos2dx.javascript.AppActivity.setup(AppActivity.java:619)
                                                                           at org.cocos2dx.javascript.AppActivity.onCreate_aroundBody0(AppActivity.java:178)
                                                                           at org.cocos2dx.javascript.AppActivity$AjcClosure1.run(AppActivity.java:1)
                                                                           at org.a.b.b.c.c(JoinPointImpl.java:149)
                                                                           at c.a.a.a.a(Hugo.java:39)
                                                                           at org.cocos2dx.javascript.AppActivity.onCreate(AppActivity.java:146)
                                                                           at android.app.Activity.performCreate(Activity.java:6245)
                                                                           at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1130)
                                                                           at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2379)
                                                                           at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2490)
                                                                           at android.app.ActivityThread.-wrap11(ActivityThread.java)
                                                                           at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1354)
                                                                           at android.os.Handler.dispatchMessage(Handler.java:102)
                                                                           at android.os.Looper.loop(Looper.java:148)
                                                                           at android.app.ActivityThread.main(ActivityThread.java:5443)
                                                                           at java.lang.reflect.Method.invoke(Native Method)
                                                                           at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:728)
                                                                           at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:618)
03-12 17:00:06.235 16874-17523/in.playsimple.word_up I/Process: Sending signal. PID: 16874 SIG: 9

【问题讨论】:

  • 检查您的接收器代码逻辑。是否已正确注销

标签: android mopub


【解决方案1】:

将以下规则添加到您的 proguard 文件中:

-keepclassmembers class com.mopub.mobileads.CustomEventBannerAdapter {!private !public !protected *;}

【讨论】:

  • 它解决了您的问题还是仍然面临同样的问题?
猜你喜欢
  • 1970-01-01
  • 1970-01-01
  • 2016-05-21
  • 1970-01-01
  • 1970-01-01
  • 2012-03-18
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
相关资源
最近更新 更多