Hi again, On Wed, 20 Mar 2002 15:50, [EMAIL PROTECTED] wrote: > I have been a little busy at work to look at this but it has come back and > bitten again so I raise it again.. > > We attempted to run logging in another environment and got the dreaded NPE. > The problem we have is that the NPE hides the actual message. > > My original suggestion to fix the problem was to modify the class > org.apache.log.output.AbstractTarget as follows to instantiate the class > with a default value. > > org.apache.log.output.AbstractTarget > private ErrorHandler m_errorHandler = new > org.apache.log.util.DefaultErrorHandler(); > > This would create a dependency between the org.apache.log.output package > and org.apache.log.util package.
That could be the way to go. Though it may be an even better idea to do something like private static final ErrorHandler DEFAULT_ERRORHANDLER = new DefaultErrorHandler(); private ErrorHandler m_errorHandler = DEFAULT_ERRORHANDLER; So that there is only one error handler for all the newly created targets. > I would like to see a fix to this problem and while I can patch the Logkit > code, I would much prefer the library was fixed. > > Any objections? Comments? Awaiting the patch ;) -- Cheers, Pete --------------------------------------------- We shall not cease from exploration, and the end of all our exploring will be to arrive where we started and know the place for the first time -- T.S. Eliot --------------------------------------------- -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>