重复启动应用程序时 AdMob 使模拟器崩溃
我正在尝试调试一个包含广告的应用程序,但模拟器崩溃了。当我尝试测试我的代码时,我必须手动将其设置为测试模式,这似乎很愚蠢。有没有办法防止这种情况发生,也许检测它是否处于模拟器模式并将其设置 adRequest 到测试模式?有其他人能够克服这个问题或经历过吗?至少我无法在手机上重现该问题。
当我使用 Android 模拟器时,以下是我认为导致问题的代码部分:
AdView adView = new AdView(this, AdSize.BANNER, "xxxxxx");
LinearLayout layout = (LinearLayout) this.findViewById(R.id.adview_layout);
layout.addView(adView);
AdRequest adRequest = new AdRequest();
adView.loadAd(adRequest);
这是来自 LogCat 的日志:
07-05 10:45:10.627: INFO/ActivityManager(70): Starting activity: Intent { dat=content://com.simpleclock.widget/appwidgets/1 cmp=hobodroid.clock.widget/.Settings (has extras) }
07-05 10:45:10.627: WARN/ActivityManager(70): startActivity called from non-Activity context; forcing Intent.FLAG_ACTIVITY_NEW_TASK for: Intent { dat=content://com.simpleclock.widget/appwidgets/1 cmp=hobodroid.clock.widget/.Settings (has extras) }
07-05 10:45:10.977: INFO/Ads(3527): To get test ads on this device, call adRequest.addTestDevice(AdRequest.TEST_EMULATOR);
07-05 10:45:11.037: INFO/Ads(3527): adRequestUrlHtml: <html><head><script src="http://www.gstatic.com/afma/sdk-core-v40.js"></script><script>AFMA_buildAdURL({"msid":"hobodroid.clock.widget","simulator":1,"hl":"en","preqs":1,"u_so":"p","slotname":"a14e0eda6eb26ea","js":"afma-sdk-a-v4.1.0","app_name":"8.android.hobodroid.clock.widget","isu":"B3EEABB8EE11C2BE770B684D95219ECB","u_audio":4,"u_w":320,"cap":"m,a","format":"320x50_mb","u_sd":1.5,"net":"ed","u_h":533});</script></head><body></body></html>
07-05 10:45:11.307: INFO/ActivityManager(70): Displayed activity hobodroid.clock.widget/.Settings: 662 ms (total 662 ms)
07-05 10:45:11.947: INFO/Ads(3527): Received ad url: <"url": "http://r.admob.com:80/ad_source.php?msid=hobodroid.clock.widget&hl=en&preqs=1&u_so=p&slotname=a14e0eda6eb26ea&js=afma-sdk-a-v4.1.0&app_name=8.android.hobodroid.clock.widget&isu=B3EEABB8EE11C2BE770B684D95219ECB&u_audio=4&u_w=320&cap=m%2Ca&format=320x50_mb&u_sd=1.5&net=ed&u_h=533&output=html®ion=mobile_app&u_tz=-120&ex=1&client_sdk=1&askip=1", "afmaNotifyDt": "null">
07-05 10:45:12.427: INFO/Ads(3527): onReceiveAd()
07-05 10:45:13.217: WARN/KeyCharacterMap(3527): No keyboard for id 0
07-05 10:45:13.217: WARN/KeyCharacterMap(3527): Using default keymap: /system/usr/keychars/qwerty.kcm.bin
07-05 10:45:14.307: INFO/DEBUG(27): *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
07-05 10:45:14.317: INFO/DEBUG(27): Build fingerprint: 'generic/sdk/generic/:1.6/Donut/20842:eng/test-keys'
07-05 10:45:14.317: INFO/DEBUG(27): pid: 3527, tid: 3537 >>> hobodroid.clock.widget <<<
07-05 10:45:14.317: INFO/DEBUG(27): signal 11 (SIGSEGV), fault addr 00000000
07-05 10:45:14.317: INFO/DEBUG(27): r0 00000007 r1 411b9a50 r2 411b9a50 r3 00000000
07-05 10:45:14.317: INFO/DEBUG(27): r4 411b9a50 r5 00280df0 r6 00000000 r7 44cc8cac
07-05 10:45:14.317: INFO/DEBUG(27): r8 44cc8da0 r9 424c2e48 10 424c2e34 fp 00000001
07-05 10:45:14.317: INFO/DEBUG(27): ip ad083e5c sp 44cc8c48 lr ad047361 pc ad03fc86 cpsr 00000030
07-05 10:45:14.487: INFO/DEBUG(27): #00 pc 0003fc86 /system/lib/libdvm.so
07-05 10:45:14.498: INFO/DEBUG(27): #01 pc 0002f480 /system/lib/libdvm.so
07-05 10:45:14.498: INFO/DEBUG(27): #02 pc 001f3c52 /system/lib/libwebcore.so
07-05 10:45:14.498: INFO/DEBUG(27): #03 pc 00260b62 /system/lib/libwebcore.so
07-05 10:45:14.498: INFO/DEBUG(27): #04 pc 000dac80 /system/lib/libwebcore.so
07-05 10:45:14.498: INFO/DEBUG(27): #05 pc 000ecc6c /system/lib/libwebcore.so
07-05 10:45:14.507: INFO/DEBUG(27): #06 pc 000df90c /system/lib/libwebcore.so
07-05 10:45:14.507: INFO/DEBUG(27): #07 pc 00188640 /system/lib/libwebcore.so
07-05 10:45:14.507: INFO/DEBUG(27): #08 pc 001887bc /system/lib/libwebcore.so
07-05 10:45:14.507: INFO/DEBUG(27): #09 pc 001887e8 /system/lib/libwebcore.so
07-05 10:45:14.507: INFO/DEBUG(27): #10 pc 00258ab6 /system/lib/libwebcore.so
07-05 10:45:14.507: INFO/DEBUG(27): #11 pc 0000e434 /system/lib/libdvm.so
07-05 10:45:14.517: INFO/DEBUG(27): #12 pc 00040b0e /system/lib/libdvm.so
07-05 10:45:14.517: INFO/DEBUG(27): #13 pc 00013198 /system/lib/libdvm.so
07-05 10:45:14.517: INFO/DEBUG(27): #14 pc 00017be4 /system/lib/libdvm.so
07-05 10:45:14.517: INFO/DEBUG(27): #15 pc 0001762c /system/lib/libdvm.so
07-05 10:45:14.517: INFO/DEBUG(27): #16 pc 0005282c /system/lib/libdvm.so
07-05 10:45:14.517: INFO/DEBUG(27): #17 pc 0005284a /system/lib/libdvm.so
07-05 10:45:14.517: INFO/DEBUG(27): #18 pc 00047800 /system/lib/libdvm.so
07-05 10:45:14.527: INFO/DEBUG(27): #19 pc 0000f940 /system/lib/libc.so
07-05 10:45:14.527: INFO/DEBUG(27): #20 pc 0000f4b4 /system/lib/libc.so
07-05 10:45:14.527: INFO/DEBUG(27): stack:
07-05 10:45:14.527: INFO/DEBUG(27): 44cc8c08 44cc8c40
07-05 10:45:14.527: INFO/DEBUG(27): 44cc8c0c 00280df0 [heap]
07-05 10:45:14.527: INFO/DEBUG(27): 44cc8c10 4182712a /data/dalvik-cache/system@[email protected]@classes.dex
07-05 10:45:14.527: INFO/DEBUG(27): 44cc8c14 4182712b /data/dalvik-cache/system@[email protected]@classes.dex
07-05 10:45:14.527: INFO/DEBUG(27): 44cc8c18 00280df0 [heap]
07-05 10:45:14.527: INFO/DEBUG(27): 44cc8c1c 00000001
07-05 10:45:14.527: INFO/DEBUG(27): 44cc8c20 00000007
07-05 10:45:14.527: INFO/DEBUG(27): 44cc8c24 4106ffe0 /dev/ashmem/dalvik-LinearAlloc (deleted)
07-05 10:45:14.537: INFO/DEBUG(27): 44cc8c28 00280df0 [heap]
07-05 10:45:14.537: INFO/DEBUG(27): 44cc8c2c 00000001
07-05 10:45:14.537: INFO/DEBUG(27): 44cc8c30 00000007
07-05 10:45:14.537: INFO/DEBUG(27): 44cc8c34 ad047361 /system/lib/libdvm.so
07-05 10:45:14.537: INFO/DEBUG(27): 44cc8c38 411b9a50 /dev/ashmem/dalvik-LinearAlloc (deleted)
07-05 10:45:14.537: INFO/DEBUG(27): 44cc8c3c 00280df0 [heap]
07-05 10:45:14.537: INFO/DEBUG(27): 44cc8c40 df002777
07-05 10:45:14.537: INFO/DEBUG(27): 44cc8c44 e3a070ad
07-05 10:45:14.537: INFO/DEBUG(27): #00 44cc8c48 002cf510 [heap]
07-05 10:45:14.537: INFO/DEBUG(27): 44cc8c4c ad06c894 /system/lib/libdvm.so
07-05 10:45:14.537: INFO/DEBUG(27): 44cc8c50 ad03ff19 /system/lib/libdvm.so
07-05 10:45:14.537: INFO/DEBUG(27): 44cc8c54 ad06c608 /system/lib/libdvm.so
07-05 10:45:14.537: INFO/DEBUG(27): 44cc8c58 439ab0d8 /dev/ashmem/mspace/dalvik-heap/2 (deleted)
07-05 10:45:14.537: INFO/DEBUG(27): 44cc8c5c ad06c608 /system/lib/libdvm.so
07-05 10:45:14.547: INFO/DEBUG(27): 44cc8c60 ad03fc71 /system/lib/libdvm.so
07-05 10:45:14.547: INFO/DEBUG(27): 44cc8c64 00297fb8 [heap]
07-05 10:45:14.547: INFO/DEBUG(27): 44cc8c68 00000000
07-05 10:45:14.547: INFO/DEBUG(27): 44cc8c6c ad02f483 /system/lib/libdvm.so
07-05 10:45:14.547: INFO/DEBUG(27): #01 44cc8c70 ad06c608 /system/lib/libdvm.so
07-05 10:45:14.547: INFO/DEBUG(27): 44cc8c74 ad02ff11 /system/lib/libdvm.so
07-05 10:45:14.547: INFO/DEBUG(27): 44cc8c78 44cc8cac
07-05 10:45:14.547: INFO/DEBUG(27): 44cc8c7c 411b9a50 /dev/ashmem/dalvik-LinearAlloc (deleted)
07-05 10:45:14.547: INFO/DEBUG(27): 44cc8c80 aa3dc5d0 /system/lib/libwebcore.so
07-05 10:45:14.547: INFO/DEBUG(27): 44cc8c84 ad02f409 /system/lib/libdvm.so
07-05 10:45:14.547: INFO/DEBUG(27): 44cc8c88 aa1f3c3d /system/lib/libwebcore.so
07-05 10:45:14.547: INFO/DEBUG(27): 44cc8c8c 00297fb8 [heap]
07-05 10:45:14.547: INFO/DEBUG(27): 44cc8c90 00000000
07-05 10:45:14.547: INFO/DEBUG(27): 44cc8c94 aa1f3c55 /system/lib/libwebcore.so
07-05 10:45:15.077: INFO/ActivityManager(70): Starting activity: Intent { dat=content://com.simpleclock.widget/appwidgets/1 cmp=hobodroid.clock.widget/.Settings (has extras) }
07-05 10:45:15.077: WARN/ActivityManager(70): startActivity called from non-Activity context; forcing Intent.FLAG_ACTIVITY_NEW_TASK for: Intent { dat=content://com.simpleclock.widget/appwidgets/1 cmp=hobodroid.clock.widget/.Settings (has extras) }
07-05 10:45:15.577: INFO/Ads(3527): To get test ads on this device, call adRequest.addTestDevice(AdRequest.TEST_EMULATOR);
07-05 10:45:15.637: INFO/Ads(3527): adRequestUrlHtml: <html><head><script src="http://www.gstatic.com/afma/sdk-core-v40.js"></script><script>AFMA_buildAdURL({"msid":"hobodroid.clock.widget","simulator":1,"hl":"en","preqs":2,"u_so":"p","slotname":"a14e0eda6eb26ea","js":"afma-sdk-a-v4.1.0","app_name":"8.android.hobodroid.clock.widget","isu":"B3EEABB8EE11C2BE770B684D95219ECB","u_audio":4,"u_w":320,"cap":"m,a","format":"320x50_mb","u_sd":1.5,"net":"ed","u_h":533});</script></head><body></body></html>
07-05 10:45:15.877: INFO/ActivityManager(70): Displayed activity hobodroid.clock.widget/.Settings: 796 ms (total 796 ms)
07-05 10:45:16.887: INFO/ActivityManager(70): Process hobodroid.clock.widget (pid 3527) has died.
07-05 10:45:16.887: WARN/ActivityManager(70): Scheduling restart of crashed service hobodroid.clock.widget/.ClockService in 5000ms
07-05 10:45:16.897: INFO/WindowManager(70): WIN DEATH: Window{43856840 hobodroid.clock.widget/hobodroid.clock.widget.Settings paused=false}
07-05 10:45:16.937: WARN/UsageStats(70): Unexpected resume of com.android.launcher while already resumed in hobodroid.clock.widget
07-05 10:45:16.987: ERROR/ActivityThread(70): Failed to find provider info for android.server.checkin
07-05 10:45:16.987: WARN/Checkin(70): Can't log event SYSTEM_SERVICE_LOOPING: java.lang.IllegalArgumentException: Unknown URL content://android.server.checkin/events
07-05 10:45:16.997: WARN/InputManagerService(70): Got RemoteException sending setActive(false) notification to pid 3527 uid 10024
I'm trying to debug an app that has ads in it, and the emulator is crashing on me. It seems silly that I have to manually set it to test mode, when I'm trying to test out my code. Is there someway to prevent this from happening, perhapse detect if its in emulator mode and have it set the adRequest to test mode? Has anyone else been able to overcome this or experienced it? I can't recreate the problem on my phone at least.
Here is the code section that I think is causing me problems, when I'm using the Android emulator:
AdView adView = new AdView(this, AdSize.BANNER, "xxxxxx");
LinearLayout layout = (LinearLayout) this.findViewById(R.id.adview_layout);
layout.addView(adView);
AdRequest adRequest = new AdRequest();
adView.loadAd(adRequest);
Here is the log from LogCat:
07-05 10:45:10.627: INFO/ActivityManager(70): Starting activity: Intent { dat=content://com.simpleclock.widget/appwidgets/1 cmp=hobodroid.clock.widget/.Settings (has extras) }
07-05 10:45:10.627: WARN/ActivityManager(70): startActivity called from non-Activity context; forcing Intent.FLAG_ACTIVITY_NEW_TASK for: Intent { dat=content://com.simpleclock.widget/appwidgets/1 cmp=hobodroid.clock.widget/.Settings (has extras) }
07-05 10:45:10.977: INFO/Ads(3527): To get test ads on this device, call adRequest.addTestDevice(AdRequest.TEST_EMULATOR);
07-05 10:45:11.037: INFO/Ads(3527): adRequestUrlHtml: <html><head><script src="http://www.gstatic.com/afma/sdk-core-v40.js"></script><script>AFMA_buildAdURL({"msid":"hobodroid.clock.widget","simulator":1,"hl":"en","preqs":1,"u_so":"p","slotname":"a14e0eda6eb26ea","js":"afma-sdk-a-v4.1.0","app_name":"8.android.hobodroid.clock.widget","isu":"B3EEABB8EE11C2BE770B684D95219ECB","u_audio":4,"u_w":320,"cap":"m,a","format":"320x50_mb","u_sd":1.5,"net":"ed","u_h":533});</script></head><body></body></html>
07-05 10:45:11.307: INFO/ActivityManager(70): Displayed activity hobodroid.clock.widget/.Settings: 662 ms (total 662 ms)
07-05 10:45:11.947: INFO/Ads(3527): Received ad url: <"url": "http://r.admob.com:80/ad_source.php?msid=hobodroid.clock.widget&hl=en&preqs=1&u_so=p&slotname=a14e0eda6eb26ea&js=afma-sdk-a-v4.1.0&app_name=8.android.hobodroid.clock.widget&isu=B3EEABB8EE11C2BE770B684D95219ECB&u_audio=4&u_w=320&cap=m%2Ca&format=320x50_mb&u_sd=1.5&net=ed&u_h=533&output=html®ion=mobile_app&u_tz=-120&ex=1&client_sdk=1&askip=1", "afmaNotifyDt": "null">
07-05 10:45:12.427: INFO/Ads(3527): onReceiveAd()
07-05 10:45:13.217: WARN/KeyCharacterMap(3527): No keyboard for id 0
07-05 10:45:13.217: WARN/KeyCharacterMap(3527): Using default keymap: /system/usr/keychars/qwerty.kcm.bin
07-05 10:45:14.307: INFO/DEBUG(27): *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
07-05 10:45:14.317: INFO/DEBUG(27): Build fingerprint: 'generic/sdk/generic/:1.6/Donut/20842:eng/test-keys'
07-05 10:45:14.317: INFO/DEBUG(27): pid: 3527, tid: 3537 >>> hobodroid.clock.widget <<<
07-05 10:45:14.317: INFO/DEBUG(27): signal 11 (SIGSEGV), fault addr 00000000
07-05 10:45:14.317: INFO/DEBUG(27): r0 00000007 r1 411b9a50 r2 411b9a50 r3 00000000
07-05 10:45:14.317: INFO/DEBUG(27): r4 411b9a50 r5 00280df0 r6 00000000 r7 44cc8cac
07-05 10:45:14.317: INFO/DEBUG(27): r8 44cc8da0 r9 424c2e48 10 424c2e34 fp 00000001
07-05 10:45:14.317: INFO/DEBUG(27): ip ad083e5c sp 44cc8c48 lr ad047361 pc ad03fc86 cpsr 00000030
07-05 10:45:14.487: INFO/DEBUG(27): #00 pc 0003fc86 /system/lib/libdvm.so
07-05 10:45:14.498: INFO/DEBUG(27): #01 pc 0002f480 /system/lib/libdvm.so
07-05 10:45:14.498: INFO/DEBUG(27): #02 pc 001f3c52 /system/lib/libwebcore.so
07-05 10:45:14.498: INFO/DEBUG(27): #03 pc 00260b62 /system/lib/libwebcore.so
07-05 10:45:14.498: INFO/DEBUG(27): #04 pc 000dac80 /system/lib/libwebcore.so
07-05 10:45:14.498: INFO/DEBUG(27): #05 pc 000ecc6c /system/lib/libwebcore.so
07-05 10:45:14.507: INFO/DEBUG(27): #06 pc 000df90c /system/lib/libwebcore.so
07-05 10:45:14.507: INFO/DEBUG(27): #07 pc 00188640 /system/lib/libwebcore.so
07-05 10:45:14.507: INFO/DEBUG(27): #08 pc 001887bc /system/lib/libwebcore.so
07-05 10:45:14.507: INFO/DEBUG(27): #09 pc 001887e8 /system/lib/libwebcore.so
07-05 10:45:14.507: INFO/DEBUG(27): #10 pc 00258ab6 /system/lib/libwebcore.so
07-05 10:45:14.507: INFO/DEBUG(27): #11 pc 0000e434 /system/lib/libdvm.so
07-05 10:45:14.517: INFO/DEBUG(27): #12 pc 00040b0e /system/lib/libdvm.so
07-05 10:45:14.517: INFO/DEBUG(27): #13 pc 00013198 /system/lib/libdvm.so
07-05 10:45:14.517: INFO/DEBUG(27): #14 pc 00017be4 /system/lib/libdvm.so
07-05 10:45:14.517: INFO/DEBUG(27): #15 pc 0001762c /system/lib/libdvm.so
07-05 10:45:14.517: INFO/DEBUG(27): #16 pc 0005282c /system/lib/libdvm.so
07-05 10:45:14.517: INFO/DEBUG(27): #17 pc 0005284a /system/lib/libdvm.so
07-05 10:45:14.517: INFO/DEBUG(27): #18 pc 00047800 /system/lib/libdvm.so
07-05 10:45:14.527: INFO/DEBUG(27): #19 pc 0000f940 /system/lib/libc.so
07-05 10:45:14.527: INFO/DEBUG(27): #20 pc 0000f4b4 /system/lib/libc.so
07-05 10:45:14.527: INFO/DEBUG(27): stack:
07-05 10:45:14.527: INFO/DEBUG(27): 44cc8c08 44cc8c40
07-05 10:45:14.527: INFO/DEBUG(27): 44cc8c0c 00280df0 [heap]
07-05 10:45:14.527: INFO/DEBUG(27): 44cc8c10 4182712a /data/dalvik-cache/system@[email protected]@classes.dex
07-05 10:45:14.527: INFO/DEBUG(27): 44cc8c14 4182712b /data/dalvik-cache/system@[email protected]@classes.dex
07-05 10:45:14.527: INFO/DEBUG(27): 44cc8c18 00280df0 [heap]
07-05 10:45:14.527: INFO/DEBUG(27): 44cc8c1c 00000001
07-05 10:45:14.527: INFO/DEBUG(27): 44cc8c20 00000007
07-05 10:45:14.527: INFO/DEBUG(27): 44cc8c24 4106ffe0 /dev/ashmem/dalvik-LinearAlloc (deleted)
07-05 10:45:14.537: INFO/DEBUG(27): 44cc8c28 00280df0 [heap]
07-05 10:45:14.537: INFO/DEBUG(27): 44cc8c2c 00000001
07-05 10:45:14.537: INFO/DEBUG(27): 44cc8c30 00000007
07-05 10:45:14.537: INFO/DEBUG(27): 44cc8c34 ad047361 /system/lib/libdvm.so
07-05 10:45:14.537: INFO/DEBUG(27): 44cc8c38 411b9a50 /dev/ashmem/dalvik-LinearAlloc (deleted)
07-05 10:45:14.537: INFO/DEBUG(27): 44cc8c3c 00280df0 [heap]
07-05 10:45:14.537: INFO/DEBUG(27): 44cc8c40 df002777
07-05 10:45:14.537: INFO/DEBUG(27): 44cc8c44 e3a070ad
07-05 10:45:14.537: INFO/DEBUG(27): #00 44cc8c48 002cf510 [heap]
07-05 10:45:14.537: INFO/DEBUG(27): 44cc8c4c ad06c894 /system/lib/libdvm.so
07-05 10:45:14.537: INFO/DEBUG(27): 44cc8c50 ad03ff19 /system/lib/libdvm.so
07-05 10:45:14.537: INFO/DEBUG(27): 44cc8c54 ad06c608 /system/lib/libdvm.so
07-05 10:45:14.537: INFO/DEBUG(27): 44cc8c58 439ab0d8 /dev/ashmem/mspace/dalvik-heap/2 (deleted)
07-05 10:45:14.537: INFO/DEBUG(27): 44cc8c5c ad06c608 /system/lib/libdvm.so
07-05 10:45:14.547: INFO/DEBUG(27): 44cc8c60 ad03fc71 /system/lib/libdvm.so
07-05 10:45:14.547: INFO/DEBUG(27): 44cc8c64 00297fb8 [heap]
07-05 10:45:14.547: INFO/DEBUG(27): 44cc8c68 00000000
07-05 10:45:14.547: INFO/DEBUG(27): 44cc8c6c ad02f483 /system/lib/libdvm.so
07-05 10:45:14.547: INFO/DEBUG(27): #01 44cc8c70 ad06c608 /system/lib/libdvm.so
07-05 10:45:14.547: INFO/DEBUG(27): 44cc8c74 ad02ff11 /system/lib/libdvm.so
07-05 10:45:14.547: INFO/DEBUG(27): 44cc8c78 44cc8cac
07-05 10:45:14.547: INFO/DEBUG(27): 44cc8c7c 411b9a50 /dev/ashmem/dalvik-LinearAlloc (deleted)
07-05 10:45:14.547: INFO/DEBUG(27): 44cc8c80 aa3dc5d0 /system/lib/libwebcore.so
07-05 10:45:14.547: INFO/DEBUG(27): 44cc8c84 ad02f409 /system/lib/libdvm.so
07-05 10:45:14.547: INFO/DEBUG(27): 44cc8c88 aa1f3c3d /system/lib/libwebcore.so
07-05 10:45:14.547: INFO/DEBUG(27): 44cc8c8c 00297fb8 [heap]
07-05 10:45:14.547: INFO/DEBUG(27): 44cc8c90 00000000
07-05 10:45:14.547: INFO/DEBUG(27): 44cc8c94 aa1f3c55 /system/lib/libwebcore.so
07-05 10:45:15.077: INFO/ActivityManager(70): Starting activity: Intent { dat=content://com.simpleclock.widget/appwidgets/1 cmp=hobodroid.clock.widget/.Settings (has extras) }
07-05 10:45:15.077: WARN/ActivityManager(70): startActivity called from non-Activity context; forcing Intent.FLAG_ACTIVITY_NEW_TASK for: Intent { dat=content://com.simpleclock.widget/appwidgets/1 cmp=hobodroid.clock.widget/.Settings (has extras) }
07-05 10:45:15.577: INFO/Ads(3527): To get test ads on this device, call adRequest.addTestDevice(AdRequest.TEST_EMULATOR);
07-05 10:45:15.637: INFO/Ads(3527): adRequestUrlHtml: <html><head><script src="http://www.gstatic.com/afma/sdk-core-v40.js"></script><script>AFMA_buildAdURL({"msid":"hobodroid.clock.widget","simulator":1,"hl":"en","preqs":2,"u_so":"p","slotname":"a14e0eda6eb26ea","js":"afma-sdk-a-v4.1.0","app_name":"8.android.hobodroid.clock.widget","isu":"B3EEABB8EE11C2BE770B684D95219ECB","u_audio":4,"u_w":320,"cap":"m,a","format":"320x50_mb","u_sd":1.5,"net":"ed","u_h":533});</script></head><body></body></html>
07-05 10:45:15.877: INFO/ActivityManager(70): Displayed activity hobodroid.clock.widget/.Settings: 796 ms (total 796 ms)
07-05 10:45:16.887: INFO/ActivityManager(70): Process hobodroid.clock.widget (pid 3527) has died.
07-05 10:45:16.887: WARN/ActivityManager(70): Scheduling restart of crashed service hobodroid.clock.widget/.ClockService in 5000ms
07-05 10:45:16.897: INFO/WindowManager(70): WIN DEATH: Window{43856840 hobodroid.clock.widget/hobodroid.clock.widget.Settings paused=false}
07-05 10:45:16.937: WARN/UsageStats(70): Unexpected resume of com.android.launcher while already resumed in hobodroid.clock.widget
07-05 10:45:16.987: ERROR/ActivityThread(70): Failed to find provider info for android.server.checkin
07-05 10:45:16.987: WARN/Checkin(70): Can't log event SYSTEM_SERVICE_LOOPING: java.lang.IllegalArgumentException: Unknown URL content://android.server.checkin/events
07-05 10:45:16.997: WARN/InputManagerService(70): Got RemoteException sending setActive(false) notification to pid 3527 uid 10024
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
此处讨论了此问题 https://groups.google.com/group/google-admob-ads-sdk/browse_thread/thread/f72ed8694a28cc7d/ced66f77ddb1e3ad 和此处 http://groups.google.com/group/google-admob -ads-sdk/browse_thread/thread/eeb307a33a69765d。建议的解决方法是在 Activity.onDestroy() 中调用 adView.destroy()。似乎有帮助。
This issue is discussed here https://groups.google.com/group/google-admob-ads-sdk/browse_thread/thread/f72ed8694a28cc7d/ced66f77ddb1e3ad and here http://groups.google.com/group/google-admob-ads-sdk/browse_thread/thread/eeb307a33a69765d. The suggested workaround is to call adView.destroy() in Activity.onDestroy(). Seems to help.