[jOOQ/jOOQ#17868] StackOverflowError when resolving asterisk in parsed

query using derived table with unsuccessful meta lookups
This commit is contained in:
Lukas Eder 2025-01-15 09:39:13 +01:00
parent 7d5b31d7e8
commit 011382f043

View File

@ -122,10 +122,11 @@ final class DataTypeProxy<T> extends AbstractDataType<T> {
final void type(AbstractDataType<T> t) {
if (t instanceof DataTypeProxy<T> p) {
// [#11856] [#14343] [#14373] Prevent cycles in DataTypeProxy chains
// [#11856] [#14343] [#14373] [#17868] Prevent cycles in DataTypeProxy chains
IdentityHashMap<AbstractDataType<?>, AbstractDataType<?>> m = new IdentityHashMap<>();
m.put(this, this);
m.put(p, p);
if (m.put(p, p) != null)
return;
while (p.type() instanceof DataTypeProxy<T> p2) {
if (m.put(p2, p2) != null)