Ignore tablespace ACLs when ignoring schema ACLs.
authorNoah Misch
Sun, 12 Feb 2017 21:03:41 +0000 (16:03 -0500)
committerNoah Misch
Sun, 12 Feb 2017 21:04:09 +0000 (16:04 -0500)
commit804aad8ff46cbef9f520507bb8b4522a011cd1b2
tree2d4401677356a390a59a5cae3a380df73bee3f5d
parent86ef376bbe1b9568fa71e76ecfd3091d522368bb
Ignore tablespace ACLs when ignoring schema ACLs.

The ALTER TABLE ALTER TYPE implementation can issue DROP INDEX and
CREATE INDEX to refit existing indexes for the new column type.  Since
this CREATE INDEX is an implementation detail of an index alteration,
the ensuing DefineIndex() should skip ACL checks specific to index
creation.  It already skips the namespace ACL check.  Make it skip the
tablespace ACL check, too.  Back-patch to 9.2 (all supported versions).

Reviewed by Tom Lane.
src/backend/commands/indexcmds.c
src/test/regress/input/tablespace.source
src/test/regress/output/tablespace.source