Christoph Leuzinger created BATIK-1076:
------------------------------------------
Summary: NPE in LocalizableSupport when loaded by the bootstrap
classloader
Key: BATIK-1076
URL: https://issues.apache.org/jira/browse/BATIK-1076
Project: Batik
Issue Type: Bug
Affects Versions: 1.7
Reporter: Christoph Leuzinger
Priority: Minor
We've encountered a NPE when running our application with Batik on the endorsed
classpath. The problem lies in {{LocalizableSupport.lookupResourceBundle()}}:
{code:title=LocalizableSupport.java, line 272}
if (cl == null)
cl = getClass().getClassLoader();
try {
rb = ResourceBundle.getBundle(bundle, usedLocale, cl);
} catch (MissingResourceException mre) {
}
{code}
Because the class has been loaded by the bootstrap classloader,
{{getClass().getClassLoader()}} will return {{null}} and lead to a NPE in
{{ResourceBundle.getBundle()}}.
--
This message was sent by Atlassian JIRA
(v6.2#6252)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]