1.1 --- a/java/sql-dk/src/info/globalcode/sql/dk/CLIStarter.java Thu Dec 26 00:18:03 2013 +0100
1.2 +++ b/java/sql-dk/src/info/globalcode/sql/dk/CLIStarter.java Thu Dec 26 00:58:00 2013 +0100
1.3 @@ -29,6 +29,7 @@
1.4 import java.io.IOException;
1.5 import java.sql.SQLException;
1.6 import java.util.logging.Level;
1.7 +import java.util.logging.LogRecord;
1.8 import java.util.logging.Logger;
1.9 import javax.xml.bind.JAXBContext;
1.10 import javax.xml.bind.Unmarshaller;
1.11 @@ -49,7 +50,7 @@
1.12 public static void main(String[] args) {
1.13 log.log(Level.FINE, "Starting " + Constants.PROGRAM_NAME);
1.14 int exitCode = EXIT_EXPECTED_ERROR;
1.15 -
1.16 +
1.17 if (args.length == 0) {
1.18 args = new String[]{CLIParser.Tokens.INFO_HELP};
1.19 }
1.20 @@ -68,7 +69,10 @@
1.21 } catch (InvalidOptionsException e) {
1.22 log.log(Level.SEVERE, "Invalid CLI options", e);
1.23 for (InvalidOptionsException.OptionProblem p : e.getProblems()) {
1.24 - log.log(Level.SEVERE, "Option problem: {0}", p.getDescription());
1.25 + LogRecord r = new LogRecord(Level.SEVERE, "Option problem: {0}");
1.26 + r.setThrown(p.getException());
1.27 + r.setParameters(new Object[]{p.getDescription()});
1.28 + log.log(r);
1.29 }
1.30 } catch (ConfigurationException e) {
1.31 log.log(Level.SEVERE, "Configuration problem", e);