DIRAPI-368, DIRSERVER-2340: Fix StackOverflowError
authorStefan Seelmann <mail@stefan-seelmann.de>
Sat, 3 Apr 2021 22:16:16 +0000 (00:16 +0200)
committerStefan Seelmann <mail@stefan-seelmann.de>
Sat, 3 Apr 2021 22:16:16 +0000 (00:16 +0200)
commitc5acb33ea53806d5df6ed90679f63cb46b026e82
treea13be71c6d0b5ec571d1adf40b505a7e2d2f44f9
parent607e52b591450c12c8c4e90a2d3881529d9be2a2
DIRAPI-368, DIRSERVER-2340: Fix StackOverflowError

Fix StackOverflowError when working with entries with thousands
of attributes or values. Change the recursive algorithm to an
iterative one.
ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/factory/AddRequestFactory.java
ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/factory/ModifyRequestFactory.java
ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/factory/SearchResultEntryFactory.java
ldap/codec/core/src/test/java/org/apache/directory/api/ldap/codec/add/AddRequestTest.java
ldap/codec/core/src/test/java/org/apache/directory/api/ldap/codec/modify/ModifyRequestTest.java
ldap/codec/core/src/test/java/org/apache/directory/api/ldap/codec/search/SearchResultEntryTest.java
util/src/main/java/org/apache/directory/api/util/CollectionUtils.java [new file with mode: 0644]