今天在调试android程序的时候,因为是NDK开发,要先编译.so库再打包下载到android模拟器,所以花费的时间比較长。控制台就会报例如以下错误:

error launching activity

com.android.ddmlib.shellcommandunresponsiveexception

在百度上搜没找到答案,然后谷歌,在stackoverflow这个论坛上找到了答案,经验证能够解决问题。

解决方式:

Window->Preferences->Android->DDMS,把ADB connection time out(ADB的超时时间)设置大一些,就不会再报错了。在我这里,它的默认值是5000ms,即5秒,我把它改成了50秒。例如以下图所看到的:

原因分析:ADB的超时时间假设太短,在我们的activity launch之前,它就关闭了,所以launch activity失败。

android程序报错“error launching activity com.android.ddmlib.shellcommandunresponsiveexception”的解决方式的更多相关文章

  1. 运行编译后的程序报错 error while loading shared libraries: lib*.so: cannot open shared object file: No such file or directory

    运行编译后的程序报错  error while loading shared libraries: lib*.so: cannot open shared object file: No such f ...

  2. Android stdio 报错 error invoking main method

    打开Android stdio失败 报错:error invoking main method 想想前一天做了什么事?? 昨天把企图把Android Stdio文件包移盘,但是中途截止了,也就是说移动 ...

  3. Android Studio报错 Error: A library uses the same package as this project

    今天在导入一个项目的时候,as报错 Error: A library uses the same package as this project 经过百度Google 发现解决办法:在modules的 ...

  4. 安装Scrapy报错 error: Microsoft Visual C++ 14.0 is required解决方法

    [问题背景]:在Windows 10系统,pip install Scrapy,报错error: Microsoft Visual C++ 14.0 is required,还有提示Twisted需要 ...

  5. Android Studio报错Error:Failed to open zip file. Gradle's dependency cache may be corrupt

    Android Studio导入项目后,Gradle编译失败,报错如下. Error:Failed to open zip file. Gradle's dependency cache may be ...

  6. 启动android程序报错

    提示错误如下: The connection to adb is down, and a severe error has occured. [2010-03-11 09:36:56 - HelloO ...

  7. Android studio 报错Error:Internal error: (java.lang.ClassNotFoundException) com.google.wireless.android.sdk.stats.IntellijIndexingStats$Index

    Android studio运行make build报错 解决方法 在studio的File-->Settings-->Build, Execution, Deployment---> ...

  8. 小程序报错:出现脚本错误或者未正确调用 Page()的解决办法

    场景是两个人共同开发小程序,我使用的是pc端,另一个同事是用的mac端,我这边能够正常运行项目,代码提交到git,同事check下来发现运行报错: 出现脚本错误或者未正确调用 Page(); 如图 一 ...

  9. 安卓 android studio 报错 Could not find com.android.tools.build:gradle:3.2.1.

    报错截图如下: 解决方法:在project的builde.gradle做如下操作分别加上google()

随机推荐

  1. HDU2955-Robberies

    描述: The aspiring Roy the Robber has seen a lot of American movies, and knows that the bad guys usual ...

  2. Effective MySQL之备份与恢复

    五分钟成为一名DBA 如果我们已经有了一个MySQL生产级系统,而该产品却没有MySQL备份策略,那么我们至少应该做些什么呢?在采取任何备份策略之前,有许多有关数据库大小和存储策略引擎的用法的预备知识 ...

  3. scanf(),gets(),gechar()函数小结

    1. 使用scanf()函数从终端输入字符串时,刚开始输入的所有空格不计入当前字符串,以 space,enter,tab键结束当前字符串的输入:最后的space,enter,tab字符会留在输入缓冲区 ...

  4. JAVA并发,线程优先级

    package com.xt.thinks21_2; import java.util.concurrent.ExecutorService; import java.util.concurrent. ...

  5. 51nod 1237 最大公约数之和 V3(杜教筛)

    [题目链接] https://www.51nod.com/onlineJudge/questionCode.html#!problemId=1237 [题目大意] 求[1,n][1,n]最大公约数之和 ...

  6. java ssh

    sshj (currently best choice) https://github.com/shikhar/sshj ssh used in jenkins-ci https://github.c ...

  7. dp-史上最戳最长最臭代码-hdu-4733-G(x)

    题目链接: http://acm.hdu.edu.cn/showproblem.php?pid=4733 题目大意: 定义G(x)=x⊕(x>>1).给两个由0.1.?组成的长度相同的字符 ...

  8. Linux系统编程——进程调度浅析

    概述 操作系统要实现多进程.进程调度不可缺少. 有人说,进程调度是操作系统中最为重要的一个部分.我认为这样的说法说得太绝对了一点,就像非常多人动辄就说"某某函数比某某函数效率高XX倍&quo ...

  9. OpenCV---图片生成视频

    /** It is a batch processing interface. */ #include "stdafx.h" #include <windows.h> ...

  10. word排版论文小结

    毕业论文如何用WORD排版 本人折腾了一晚上看别人的百度经验,做个总结,方便后人看懂,其实特别简单 用WORD自动生成页码 第一种情况:从第一页或者从第二页开始设置页码 这种情况只要“插入-> ...