Add missing command for pg_maintain in comment
authorDaniel Gustafsson <dgustafsson@postgresql.org>
Mon, 30 Sep 2024 22:01:32 +0000 (00:01 +0200)
committerDaniel Gustafsson <dgustafsson@postgresql.org>
Mon, 30 Sep 2024 22:01:32 +0000 (00:01 +0200)
The comment in pg_class_aclmask_ext() which lists the allowed commands
for the pg_maintain role lacked LOCK TABLE.

Reported-by: Yusuke Sugie <btsugieyuusuke@oss.nttdata.com>
Reviewed-by: Yugo Nagata <nagata@sraoss.co.jp>
Discussion: https://postgr.es/m/034d3c60f5daba1919cd90f236b2e22d@oss.nttdata.com

src/backend/catalog/aclchk.c

index 819045203dd1b0cd752ed9078280e7b8df591248..95eb0b12277b11655cefecc24a928cd9f1a43c95 100644 (file)
@@ -3449,7 +3449,7 @@ pg_class_aclmask_ext(Oid table_oid, Oid roleid, AclMode mask,
     * Check if ACL_MAINTAIN is being checked and, if so, and not already set
     * as part of the result, then check if the user is a member of the
     * pg_maintain role, which allows VACUUM, ANALYZE, CLUSTER, REFRESH
-    * MATERIALIZED VIEW, and REINDEX on all relations.
+    * MATERIALIZED VIEW, REINDEX, and LOCK TABLE on all relations.
     */
    if (mask & ACL_MAINTAIN &&
        !(result & ACL_MAINTAIN) &&