Details
-
Bug
-
Status: Resolved
-
Major
-
Resolution: Fixed
-
1.4.0, 1.4.1, 1.4.2, 1.4.3, 1.4.4, 1.4.5, 1.4.6, 1.4.7, 1.4.8, 1.4.9, 1.4.10, 1.4.11, 1.4.12
-
None
-
Windows XP; Wicket 1.4.x.
Description
We are experiencing some problems in CharSetUtil.getEncoding(). When used, we see the following stacktrace appear:
java.lang.IndexOutOfBoundsException: Index: 4, Size: 0
at java.util.ArrayList.add(ArrayList.java:367)
at org.apache.wicket.extensions.util.encoding.CharSetMap.<init>(CharSetMap.java:238)
at org.apache.wicket.extensions.util.encoding.CharSetUtil.initialize(CharSetUtil.java:72)
at org.apache.wicket.extensions.util.encoding.CharSetUtil.getEncoding(CharSetUtil.java:102)
As I understand the code in CharSetMap, it looks like the construction of the encodings array list fails. The paths it tries to load encoding map files from yield exceptions causing the array list to remain empty.
See attached quickstart for a sample.