Code Monkey home page Code Monkey logo

Comments (8)

Chersh-Pan avatar Chersh-Pan commented on June 22, 2024

64K的数据

from android-common.

Trinea avatar Trinea commented on June 22, 2024

是指 command.getBytes() 很大?
具体什么错误?OOM?

from android-common.

Chersh-Pan avatar Chersh-Pan commented on June 22, 2024

os.write的数据不能超过64K,也就是如果commands数组过大就会出现错误

from android-common.

Trinea avatar Trinea commented on June 22, 2024

没拿这么大的数据测试过,什么场景要这么多命令,分开执行不行吗

from android-common.

Chersh-Pan avatar Chersh-Pan commented on June 22, 2024

可以也可以,只是这个存在这个问题

from android-common.

Trinea avatar Trinea commented on June 22, 2024

ok,没时间细看这个问题,你有时间的话,也可以提交 PR 修复这个问题

from android-common.

Chersh-Pan avatar Chersh-Pan commented on June 22, 2024

主要是process.getOutputStream()这个流有限制大小,改不了吧

from android-common.

ComeOn-Wuhan avatar ComeOn-Wuhan commented on June 22, 2024

发现常常死等在waitfor
我看别人都是写成线程的异步
new Thread() {
public void run() {
BufferedReader br2 = new BufferedReader(new InputStreamReader(is2));
try {
String line2 = null ;
while ((line2 = br2.readLine()) != null ) {
if (line2 != null){}
}
} catch (IOException e) {
e.printStackTrace();
}
finally{
try {
is2.close();
} catch (IOException e) {
e.printStackTrace();
}
}
}
}.start();

是不是那样处理就会更好点?

from android-common.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.