Skip to content

Commit fb35798

Browse files
committed
Fix incorrect assertion on number of array dimensions.
This has been wrong ever since the support for multi-dimensional arrays as PL/python function arguments and return values was introduced in commit 94aceed. Backpatch-through: 10 Discussion: https://www.postgresql.org/message-id/61647b8e-961c-0362-d5d3-c8a18f4a7ec6%40iki.fi
1 parent f669ba7 commit fb35798

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/pl/plpython/plpy_typeio.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -683,7 +683,7 @@ PLyList_FromArray(PLyDatumToOb *arg, Datum d)
683683
/* Array dimensions and left bounds */
684684
ndim = ARR_NDIM(array);
685685
dims = ARR_DIMS(array);
686-
Assert(ndim < MAXDIM);
686+
Assert(ndim <= MAXDIM);
687687

688688
/*
689689
* We iterate the SQL array in the physical order it's stored in the

0 commit comments

Comments
 (0)