7199858: Marshal exception is wrong

Reviewed-by: lancea
This commit is contained in:
Dmeetry Degrave 2013-02-15 01:49:36 +04:00
parent 7ba83041b1
commit 2fd9426c20

View File

@ -2189,10 +2189,7 @@ public final class TypeCodeImpl extends TypeCode
if (labelIndex == _unionLabels.length) {
// check if label has not been found
if (_defaultIndex == -1)
// throw exception if default was not expected
throw wrapper.unexpectedUnionDefault() ;
else
if (_defaultIndex != -1)
// must be of the default branch type
_memberTypes[_defaultIndex].copy(src, dst);
}