drizzle4 / roottools

Automatically exported from code.google.com/p/roottools
0 stars 0 forks source link

Null pointer on executer.sendShell using result object #11

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
The problem occurs at line 107 of Executer class.
How to reproduce:
Try sending some command passing a IResult object with the method:
public List<String> sendShell(String[] commands, int sleepTime, IResult result, 
boolean useRoot)

In the finally you do:
if(null != result) {
  result.onComplete(diag);
  response.add(Integer.toString(diag));
  RootTools.lastExitCode = diag;
}

The problem is that when result!=null, response IS null because it hasn't been 
initialized so the response.add gives a null pointer exception that causes the 
caller to crash.

This is a very important issue

Original issue reported on code.google.com by LRenault...@gmail.com on 15 Nov 2011 at 2:34

GoogleCodeExporter commented 8 years ago
Just uploaded 1.4.1 can you check to see this problem is resolved?

Original comment by Stericso...@gmail.com on 15 Nov 2011 at 3:04

GoogleCodeExporter commented 8 years ago
I downloaded your changes from svn and it is working as it should.
Thank you for your reactivity

Original comment by LRenault...@gmail.com on 15 Nov 2011 at 3:13

GoogleCodeExporter commented 8 years ago
Cool :)

Original comment by Stericso...@gmail.com on 15 Nov 2011 at 3:15

GoogleCodeExporter commented 8 years ago

Original comment by Stericso...@gmail.com on 15 Nov 2011 at 3:15