Skip to content

Commit ff8ebd5

Browse files
cigalymbladel
authored andcommitted
HHH-19079 org.hibernate.type.ComponentType#getPropertyValues should allocate extra space for discriminator column(s) when input parameter is null and number of discriminator columns greater than zero
1 parent cfdaead commit ff8ebd5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

hibernate-core/src/main/java/org/hibernate/type/ComponentType.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -440,7 +440,7 @@ public Object[] getPropertyValues(Object component, SharedSessionContractImpleme
440440
@Override
441441
public Object[] getPropertyValues(Object component) {
442442
if (component == null) {
443-
return new Object[propertySpan];
443+
return new Object[propertySpan + discriminatorColumnSpan];
444444
}
445445
else if ( component instanceof Object[] ) {
446446
// A few calls to hashCode pass the property values already in an

0 commit comments

Comments
 (0)