Bug 6112 - UnionTypeCodec fails to non-identityref value
[mdsal.git] / binding / mdsal-binding-dom-codec / src / main / java / org / opendaylight / yangtools / binding / data / codec / impl / UnionTypeCodec.java
index bdb6a99efe67abed70c44b0c476b0b0e47095129..d05503f5818031b080c05c72fc4aa57d203f90c6 100644 (file)
@@ -101,7 +101,7 @@ final class UnionTypeCodec extends ReflectionBasedCodec {
             final Object identityref;
             try {
                 identityref = idRefCodec.deserialize(input);
-            } catch (UncheckedExecutionException | ExecutionError e) {
+            } catch (UncheckedExecutionException | ExecutionError | ClassCastException e) {
                 LOG.debug("Deserialization of {} as identityref failed", e);
                 return deserializeString(input);
             }