Details
-
Type:
Bug
-
Status:
Closed
-
Resolution: Fixed
-
Affects Version/s: None
-
Fix Version/s: 1.2.2
-
Component/s: None
-
Labels:None
-
JDK version and platform:Apache Harmony on Debian
Description
TextAttributeConverter uses reflection to access non-portable instanceMap field which is not present on all VM's. Apache Harmony, specifically, does not have this field, leading to;
java.lang.InternalError: Missing TextAttribute.instanceMap
at com.thoughtworks.xstream.converters.extended.TextAttributeConverter.<clinit>(TextAttributeConverter.java:30)
at com.thoughtworks.xstream.XStream.setupConverters(XStream.java:583)
at com.thoughtworks.xstream.XStream.<init>(XStream.java:370)
at com.thoughtworks.xstream.XStream.<init>(XStream.java:316)
The source as shown at http://svn.codehaus.org/xstream/trunk/xstream/src/java/com/thoughtworks/xstream/converters/extended/TextAttributeConverter.java
contains this;
instanceMap = TextAttribute.class.getDeclaredField("instanceMap");
Can this class be changed to work on all VM's, not just Sun's RI?
Issue Links
- is related to
-
XSTR-379
EnumSetConverter fails on Harmony
-
Activity
| Field | Original Value | New Value |
|---|---|---|
| Resolution | Fixed [ 1 ] | |
| Fix Version/s | 1.x Maintenance [ 12873 ] | |
| Status | Open [ 1 ] | Resolved [ 5 ] |
| Fix Version/s | 1.x Maintenance [ 12873 ] | |
| Fix Version/s | 1.2.2 [ 13038 ] |
| Status | Resolved [ 5 ] | Closed [ 6 ] |