Initialization of custom TempStorage doesn't work -------------------------------------------------
Key: MIME4J-17 URL: https://issues.apache.org/jira/browse/MIME4J-17 Project: Mime4j Issue Type: Bug Affects Versions: 0.3 Reporter: Niklas Therning Assignee: Niklas Therning Fix For: 0.4 Rickard Ekeroth reported the following bug to the ML: I think that the code in the static initializer of the class 'TempStorage' is not correct when trying to find a custom class to load: static { String clazz = System.getProperty("org.apache.james.mime4j.tempStorage"); try { if (inst != null) { inst = (TempStorage) Class.forName(clazz).newInstance(); } } catch (Throwable t) { log.warn("Unable to create or instantiate TempStorage class '" + clazz + "' using SimpleTempStorage instead", t); } if (inst == null) { inst = new SimpleTempStorage(); } } Surely the code should check for the 'clazz' to be not null and not 'inst' to determine if it should try to load the custom temp storage class. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]