HDDS-482. NullPointer exception thrown on console when cli operation failed.

Contributed by Nandakumar.
This commit is contained in:
Anu Engineer 2019-01-02 11:30:54 -08:00
parent 13f0ee21f2
commit 0cb3316cec
1 changed files with 1 additions and 1 deletions

View File

@ -51,7 +51,7 @@ public class GenericCli implements Callable<Void>, GenericParentCommand {
try {
execute(argv);
} catch (ExecutionException ex) {
printError(ex.getCause());
printError(ex.getCause() == null ? ex : ex.getCause());
System.exit(-1);
}
}