我正在开发一个非常简单的Android应用程序。我制作了一个闪屏,主菜单和一个带有单选按钮和一个按钮的页面(根据检查的无线电按钮播放声音)。应用程序工作正常(不会崩溃)但我在logcat中一直得到所有这些错误(我使用模拟器运行应用程序)。那可能是什么?我该怎么办呢?我应该担心吗?我会在有人询问时另外发布代码,因为我不知道问题出在哪里,我不想在没有理由的情况下将所有.java和xml文件发布到垃圾邮件。
logcat中的错误:
12-07 14:24:28.301: E/ActivityThread(587): Service com.android.exchange.ExchangeService has leaked ServiceConnection com.android.emailcommon.service.ServiceProxy$ProxyConnection@40d0c8d8 that was originally bound here
12-07 14:24:28.301: E/ActivityThread(587): android.app.ServiceConnectionLeaked: Service com.android.exchange.ExchangeService has leaked ServiceConnection com.android.emailcommon.service.ServiceProxy$ProxyConnection@40d0c8d8 that was originally bound here
12-07 14:24:28.301: E/ActivityThread(587): at android.app.LoadedApk$ServiceDispatcher.<init>(LoadedApk.java:969)
12-07 14:24:28.301: E/ActivityThread(587): at android.app.LoadedApk.getServiceDispatcher(LoadedApk.java:863)
12-07 14:24:28.301: E/ActivityThread(587): at android.app.ContextImpl.bindService(ContextImpl.java:1418)
12-07 14:24:28.301: E/ActivityThread(587): at android.app.ContextImpl.bindService(ContextImpl.java:1407)
12-07 14:24:28.301: E/ActivityThread(587): at android.content.ContextWrapper.bindService(ContextWrapper.java:473)
12-07 14:24:28.301: E/ActivityThread(587): at com.android.emailcommon.service.ServiceProxy.setTask(ServiceProxy.java:157)
12-07 14:24:28.301: E/ActivityThread(587): at com.android.emailcommon.service.ServiceProxy.setTask(ServiceProxy.java:145)
12-07 14:24:28.301: E/ActivityThread(587): at com.android.emailcommon.service.AccountServiceProxy.getDeviceId(AccountServiceProxy.java:116)
12-07 14:24:28.301: E/ActivityThread(587): at com.android.exchange.ExchangeService.getDeviceId(ExchangeService.java:1249)
12-07 14:24:28.301: E/ActivityThread(587): at com.android.exchange.ExchangeService$7.run(ExchangeService.java:1856)
12-07 14:24:28.301: E/ActivityThread(587): at com.android.emailcommon.utility.Utility$2.doInBackground(Utility.java:551)
12-07 14:24:28.301: E/ActivityThread(587): at com.android.emailcommon.utility.Utility$2.doInBackground(Utility.java:549)
12-07 14:24:28.301: E/ActivityThread(587): at android.os.AsyncTask$2.call(AsyncTask.java:287)
12-07 14:24:28.301: E/ActivityThread(587): at java.util.concurrent.FutureTask.run(FutureTask.java:234)
12-07 14:24:28.301: E/ActivityThread(587): at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1080)
12-07 14:24:28.301: E/ActivityThread(587): at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:573)
12-07 14:24:28.301: E/ActivityThread(587): at java.lang.Thread.run(Thread.java:856)
12-07 14:24:28.312: E/StrictMode(587): null
12-07 14:24:28.312: E/StrictMode(587): android.app.ServiceConnectionLeaked: Service com.android.exchange.ExchangeService has leaked ServiceConnection com.android.emailcommon.service.ServiceProxy$ProxyConnection@40d0c8d8 that was originally bound here
12-07 14:24:28.312: E/StrictMode(587): at android.app.LoadedApk$ServiceDispatcher.<init>(LoadedApk.java:969)
12-07 14:24:28.312: E/StrictMode(587): at android.app.LoadedApk.getServiceDispatcher(LoadedApk.java:863)
12-07 14:24:28.312: E/StrictMode(587): at android.app.ContextImpl.bindService(ContextImpl.java:1418)
12-07 14:24:28.312: E/StrictMode(587): at android.app.ContextImpl.bindService(ContextImpl.java:1407)
12-07 14:24:28.312: E/StrictMode(587): at android.content.ContextWrapper.bindService(ContextWrapper.java:473)
12-07 14:24:28.312: E/StrictMode(587): at com.android.emailcommon.service.ServiceProxy.setTask(ServiceProxy.java:157)
12-07 14:24:28.312: E/StrictMode(587): at com.android.emailcommon.service.ServiceProxy.setTask(ServiceProxy.java:145)
12-07 14:24:28.312: E/StrictMode(587): at com.android.emailcommon.service.AccountServiceProxy.getDeviceId(AccountServiceProxy.java:116)
12-07 14:24:28.312: E/StrictMode(587): at com.android.exchange.ExchangeService.getDeviceId(ExchangeService.java:1249)
12-07 14:24:28.312: E/StrictMode(587): at com.android.exchange.ExchangeService$7.run(ExchangeService.java:1856)
12-07 14:24:28.312: E/StrictMode(587): at com.android.emailcommon.utility.Utility$2.doInBackground(Utility.java:551)
12-07 14:24:28.312: E/StrictMode(587): at com.android.emailcommon.utility.Utility$2.doInBackground(Utility.java:549)
12-07 14:24:28.312: E/StrictMode(587): at android.os.AsyncTask$2.call(AsyncTask.java:287)
12-07 14:24:28.312: E/StrictMode(587): at java.util.concurrent.FutureTask.run(FutureTask.java:234)
12-07 14:24:28.312: E/StrictMode(587): at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1080)
12-07 14:24:28.312: E/StrictMode(587): at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:573)
12-07 14:24:28.312: E/StrictMode(587): at java.lang.Thread.run(Thread.java:856)
12-07 14:24:28.312: W/ActivityManager(273): Unbind failed: could not find connection for android.os.BinderProxy@40f409d8
12-07 14:24:28.322: E/ActivityThread(587): Service com.android.exchange.ExchangeService has leaked ServiceConnection com.android.emailcommon.service.ServiceProxy$ProxyConnection@40d5ed58 that was originally bound here
12-07 14:24:28.322: E/ActivityThread(587): android.app.ServiceConnectionLeaked: Service com.android.exchange.ExchangeService has leaked ServiceConnection com.android.emailcommon.service.ServiceProxy$ProxyConnection@40d5ed58 that was originally bound here
12-07 14:24:28.322: E/ActivityThread(587): at android.app.LoadedApk$ServiceDispatcher.<init>(LoadedApk.java:969)
12-07 14:24:28.322: E/ActivityThread(587): at android.app.LoadedApk.getServiceDispatcher(LoadedApk.java:863)
12-07 14:24:28.322: E/ActivityThread(587): at android.app.ContextImpl.bindService(ContextImpl.java:1418)
12-07 14:24:28.322: E/ActivityThread(587): at android.app.ContextImpl.bindService(ContextImpl.java:1407)
12-07 14:24:28.322: E/ActivityThread(587): at android.content.ContextWrapper.bindService(ContextWrapper.java:473)
12-07 14:24:28.322: E/ActivityThread(587): at com.android.emailcommon.service.ServiceProxy.setTask(ServiceProxy.java:157)
12-07 14:24:28.322: E/ActivityThread(587): at com.android.emailcommon.service.ServiceProxy.setTask(ServiceProxy.java:145)
12-07 14:24:28.322: E/ActivityThread(587): at com.android.emailcommon.service.ServiceProxy.test(ServiceProxy.java:191)
12-07 14:24:28.322: E/ActivityThread(587): at com.android.exchange.ExchangeService$7.run(ExchangeService.java:1850)
12-07 14:24:28.322: E/ActivityThread(587): at com.android.emailcommon.utility.Utility$2.doInBackground(Utility.java:551)
12-07 14:24:28.322: E/ActivityThread(587): at com.android.emailcommon.utility.Utility$2.doInBackground(Utility.java:549)
12-07 14:24:28.322: E/ActivityThread(587): at android.os.AsyncTask$2.call(AsyncTask.java:287)
12-07 14:24:28.322: E/ActivityThread(587): at java.util.concurrent.FutureTask.run(FutureTask.java:234)
12-07 14:24:28.322: E/ActivityThread(587): at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1080)
12-07 14:24:28.322: E/ActivityThread(587): at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:573)
12-07 14:24:28.322: E/ActivityThread(587): at java.lang.Thread.run(Thread.java:856)
12-07 14:24:28.341: E/StrictMode(587): null
12-07 14:24:28.341: E/StrictMode(587): android.app.ServiceConnectionLeaked: Service com.android.exchange.ExchangeService has leaked ServiceConnection com.android.emailcommon.service.ServiceProxy$ProxyConnection@40d5ed58 that was originally bound here
12-07 14:24:28.341: E/StrictMode(587): at android.app.LoadedApk$ServiceDispatcher.<init>(LoadedApk.java:969)
12-07 14:24:28.341: E/StrictMode(587): at android.app.LoadedApk.getServiceDispatcher(LoadedApk.java:863)
12-07 14:24:28.341: E/StrictMode(587): at android.app.ContextImpl.bindService(ContextImpl.java:1418)
12-07 14:24:28.341: E/StrictMode(587): at android.app.ContextImpl.bindService(ContextImpl.java:1407)
12-07 14:24:28.341: E/StrictMode(587): at android.content.ContextWrapper.bindService(ContextWrapper.java:473)
12-07 14:24:28.341: E/StrictMode(587): at com.android.emailcommon.service.ServiceProxy.setTask(ServiceProxy.java:157)
12-07 14:24:28.341: E/StrictMode(587): at com.android.emailcommon.service.ServiceProxy.setTask(ServiceProxy.java:145)
12-07 14:24:28.341: E/StrictMode(587): at com.android.emailcommon.service.ServiceProxy.test(ServiceProxy.java:191)
12-07 14:24:28.341: E/StrictMode(587): at com.android.exchange.ExchangeService$7.run(ExchangeService.java:1850)
12-07 14:24:28.341: E/StrictMode(587): at com.android.emailcommon.utility.Utility$2.doInBackground(Utility.java:551)
12-07 14:24:28.341: E/StrictMode(587): at com.android.emailcommon.utility.Utility$2.doInBackground(Utility.java:549)
12-07 14:24:28.341: E/StrictMode(587): at android.os.AsyncTask$2.call(AsyncTask.java:287)
12-07 14:24:28.341: E/StrictMode(587): at java.util.concurrent.FutureTask.run(FutureTask.java:234)
12-07 14:24:28.341: E/StrictMode(587): at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1080)
12-07 14:24:28.341: E/StrictMode(587): at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:573)
12-07 14:24:28.341: E/StrictMode(587): at java.lang.Thread.run(Thread.java:856)
答案 0 :(得分:131)
更简单的解决方法是禁用&#34; Exchange服务&#34;在“设置:应用:全部
”下的模拟设备中(您可能需要滑动以查看&#34;所有&#34;标签)
答案 1 :(得分:6)
在删除当前的模拟器设备之前,没有任何帮助。之后我设置了一个全新的虚拟设备。我的新模拟器设备没有所有这些错误。这解决了我的问题。
答案 2 :(得分:1)
在我的情况下,有效的是关闭防火墙(我使用最新的Android版本的Windows 8机器,4.2)。
答案 3 :(得分:1)
在搜索这个错误的60分钟后,我发现我刚刚有一个infiniteloop导致这个交换服务垃圾邮件,直到app关闭。把它留在这里以防万一其他人过度思考
答案 4 :(得分:0)
这可能是模拟器中的误导性错误消息。
我很神秘,直到我连接了一个实际的设备,它在同一点崩溃,但却抱怨缺少使用许可。添加使用权限解决了问题。
这不是所有用户的问题根源,但可能适用于某些用户。