]> granicus.if.org Git - postgresql/commit
Enforce cube dimension limit in all cube construction functions
authorAlexander Korotkov <akorotkov@postgresql.org>
Thu, 30 Aug 2018 11:18:53 +0000 (14:18 +0300)
committerAlexander Korotkov <akorotkov@postgresql.org>
Fri, 31 Aug 2018 17:22:39 +0000 (20:22 +0300)
commit5fed7b24aed50a50e2e922de2bcc51458a067210
treedda616f40a1e68f5affd514d1e2c8fa514d863a6
parentdf85f8ecea535eee425ea66b3ecf852739e54cea
Enforce cube dimension limit in all cube construction functions

contrib/cube has a limit to 100 dimensions for cube datatype.  However, it's
not enforced everywhere, and one can actually construct cube with more than
100 dimensions having then trouble with dump/restore.  This commit add checks
for dimensions limit in all functions responsible for cube construction.
Backpatch to all supported versions.

Reported-by: Andrew Gierth
Discussion: https://postgr.es/m/87va7uybt4.fsf%40news-spur.riddles.org.uk
Author: Andrey Borodin with small additions by me
Review: Tom Lane
Backpatch-through: 9.3
contrib/cube/cube.c
contrib/cube/expected/cube.out
contrib/cube/sql/cube.sql