]
Pete Muir updated JBSEAM-2526:
------------------------------
Fix Version/s: 2.1.0.GA
org.jboss.seam.core.SeamResourceBundle::getKeys()
-------------------------------------------------
Key: JBSEAM-2526
URL:
http://jira.jboss.com/jira/browse/JBSEAM-2526
Project: JBoss Seam
Issue Type: Bug
Components: Core
Affects Versions: 2.0.1.CR1
Reporter: Antoni Jakubiak
Assigned To: Norman Richards
Priority: Trivial
Fix For: 2.1.0.GA, 2.0.1.GA
Please, take a look at this code:
org.jboss.seam.core.SeamResourceBundle
public Enumeration<String> getKeys()
{
List<java.util.ResourceBundle> pageBundles = getPageResourceBundles();
List<ResourceBundle> bundles = getBundlesForCurrentLocale();
Enumeration<String>[] enumerations = new Enumeration[bundles.size() +
pageBundles.size()];
int i = 0;
for (; i < pageBundles.size(); i++)
{
enumerations[i++] = pageBundles.get(i).getKeys();
}
for (; i < bundles.size(); i++)
{
enumerations[i] = bundles.get(i).getKeys();
}
[...]
}
Loops doesn't look ok for me. I think, it shoud be:
int j = 0;
int i;
for (i = 0; i < pageBundles.size(); i++, j++)
{
enumerations[ j ] = pageBundles.get(i).getKeys();
}
for (i = 0; i < bundles.size(); i++, j++)
{
enumerations[ j ] = bundles.get(i).getKeys();
}
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: