Opened 7 years ago
Closed 7 years ago
#3404 closed defect (fixed)
ST_ClusterWithin crashes backend
|Reported by:||dbaston||Owned by:||dbaston|
The UF_ordered_by_cluster function assumes that
UF_find will fully compress all paths, ie after a call to
UF_find(uf, i), we can say that
uf->clusters[i] = UF_find(uf, i).
It's possible to end up with a situation where this does not hold; I've run across one in an input set of 24,000 points. The consequence of this is that the
combine_geometries routine will produce more geometries than expected, and will overflow a block of allocated memory.
I'll commit a fix to (a) make sure that
UF_find fully compresses paths, resolving the root cause of the problem, and (b) include a guard in
combine_geometries so that we can return an error instead of overflowing.
Change History (2)
comment:1 by , 7 years ago
|Status:||new → assigned|
comment:2 by , 7 years ago
|Status:||assigned → closed|
Fixed in trunk at r14507, 2.2 at r14508