Skip to content

Commit 7d06f20

Browse files
authored
NPE in ExpressionOperator.printCollection - backport from 2.7 (#2141)
Fixes #2136 Backport from #2137 Signed-off-by: Radek Felcman <radek.felcman@oracle.com>
1 parent a12b803 commit 7d06f20

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

foundation/org.eclipse.persistence.core/src/main/java/org/eclipse/persistence/expressions/ExpressionOperator.java

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 1998, 2022 Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 1998, 2024 Oracle and/or its affiliates. All rights reserved.
33
* Copyright (c) 2018, 2022 IBM Corporation. All rights reserved.
44
*
55
* This program and the accompanying materials are made available under the
@@ -2387,8 +2387,7 @@ public void printCollection(List<Expression> items, ExpressionSQLPrinter printer
23872387
}
23882388

23892389
String[] dbStrings = getDatabaseStrings(items.size());
2390-
for (int i = 0; i < this.argumentIndices.length; i++) {
2391-
final int index = this.argumentIndices[i];
2390+
for (final int index : this.argumentIndices) {
23922391
Expression item = items.get(index);
23932392
if ((this.selector == Ref) || ((this.selector == Deref) && (item.isObjectExpression()))) {
23942393
DatabaseTable alias = item.aliasForTable(((ObjectExpression)item).getDescriptor().getTables().firstElement());

0 commit comments

Comments
 (0)