Turning logging off causes Exception

Description

Problem #1:
Turning logging off with the simple element

<logging level="OFF" />

causes the following exception when running an installer.:

Exception in thread "IzPack - Unpacker thread" java.lang.NullPointerException
at com.izforge.izpack.util.LogUtils.loadConfiguration(LogUtils.java:97)
at com.izforge.izpack.util.LogUtils.loadLoggingResource(LogUtils.java:235)
at com.izforge.izpack.util.LogUtils.loadConfiguration(LogUtils.java:66)
at com.izforge.izpack.installer.unpacker.UnpackerBase.resetLogging(UnpackerBase.java:1394)
at com.izforge.izpack.installer.unpacker.UnpackerBase.run(UnpackerBase.java:241)
at java.lang.Thread.run(Thread.java:745)

Problem #2:

You can work around this issue by changing this to:

<logging level="OFF">
<log-file pattern="$INSTALL_PATH/install.log" append="true" mkdirs="true" />
</logging>

But this both writes a log file and still displays messages. E.g.

$ java -jar SMP-2.1.6.jar
[ Writing the uninstaller data ... ]

My suggestion is that setting logging OFF should silence all output and some command line options ought to restore it, possibly at specified log4j levels.

Environment

None

Assignee

Unassigned

Reporter

Andrew Hall

Impact

None

Components

Fix versions

Affects versions

Priority

High
Configure