Issue | Fix Version | Assignee | Priority | Status | Resolution | Resolved In Build |
---|---|---|---|---|---|---|
JDK-2203350 | 7 | Miroslaw Niemiec | P2 | Resolved | Fixed | b123 |
JDK-2186684 | 6u19 | Miroslaw Niemiec | P4 | Resolved | Fixed | b01 |
JDK-2189212 | 6u18-rev | Miroslaw Niemiec | P4 | Resolved | Fixed | b09 |
JDK-2183428 | 6u17-rev | Miroslaw Niemiec | P4 | Closed | Fixed | b06 |
FULL PRODUCT VERSION :
ADDITIONAL OS VERSION INFORMATION :
Windows_NT <MACHINE NAME> 5 01 586
A DESCRIPTION OF THE PROBLEM :
For the class java.lang.Enum, as per Java to IDL mapping spec example, the SVUID should be 0L. The SVUID calculated by com.sun.corba.se.impl.io.ObjectStreamClass for java.lang.Enum is not 0L. Also, in the hashcode calculation, the getFields() method does NOT return 0 fields for java.lang.Enum.
In java.io.ObjectStreamClass however, we have the following code:
if (isEnum) {
suid = Long.valueOf(0);
fields = NO_FIELDS;
return null;
}
Shouldn't the same be done in com.sun.corba.se.impl.io.ObjectStreamClass?
Shouldn't the SVUID be 0L, and getFields return NO_FIELDS?
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
i was expecting the SVUID to be 0L, and the getFields to return NO_FIELDS.
ACTUAL -
SVUID is not 0L, and getFields returns an array of length 2
REPRODUCIBILITY :
This bug can be reproduced always.
ADDITIONAL OS VERSION INFORMATION :
Windows_NT <MACHINE NAME> 5 01 586
A DESCRIPTION OF THE PROBLEM :
For the class java.lang.Enum, as per Java to IDL mapping spec example, the SVUID should be 0L. The SVUID calculated by com.sun.corba.se.impl.io.ObjectStreamClass for java.lang.Enum is not 0L. Also, in the hashcode calculation, the getFields() method does NOT return 0 fields for java.lang.Enum.
In java.io.ObjectStreamClass however, we have the following code:
if (isEnum) {
suid = Long.valueOf(0);
fields = NO_FIELDS;
return null;
}
Shouldn't the same be done in com.sun.corba.se.impl.io.ObjectStreamClass?
Shouldn't the SVUID be 0L, and getFields return NO_FIELDS?
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
i was expecting the SVUID to be 0L, and the getFields to return NO_FIELDS.
ACTUAL -
SVUID is not 0L, and getFields returns an array of length 2
REPRODUCIBILITY :
This bug can be reproduced always.
- backported by
-
JDK-2203350 SVUID calculated for java.lang.Enum is not 0L
- Resolved
-
JDK-2186684 SVUID calculated for java.lang.Enum is not 0L
- Resolved
-
JDK-2189212 SVUID calculated for java.lang.Enum is not 0L
- Resolved
-
JDK-2183428 SVUID calculated for java.lang.Enum is not 0L
- Closed
- relates to
-
JDK-7046882 Regression : Enum exchanged as parameters using CORBA call results in Exception
- Resolved
-
JDK-6277781 Serialization of Enums over IIOP is broke.
- Resolved
(1 relates to)