diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2001-11-16 23:30:35 +0000 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2001-11-16 23:30:35 +0000 |
commit | c845b4272c572efd372b026201c95d58c0b0043f (patch) | |
tree | 6f12e21e991e591046c1d5df94e2fd19404952e7 /src/backend/utils/adt/acl.c | |
parent | aea081bb275211f9d9e68a05db8c8b3eb31f2585 (diff) | |
download | postgresql-c845b4272c572efd372b026201c95d58c0b0043f.tar.gz postgresql-c845b4272c572efd372b026201c95d58c0b0043f.zip |
IsSystemRelationName() treats TOAST relations as system relations.
This seems the right thing for most usages, but I notice two places
where it is the wrong thing. One is that the default permissions on
TOAST rels should be no-access, not world-readable; the other is that
PrepareForTupleInvalidation doesn't really need to spend time looking
at tuples of TOAST relations.
Diffstat (limited to 'src/backend/utils/adt/acl.c')
-rw-r--r-- | src/backend/utils/adt/acl.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/backend/utils/adt/acl.c b/src/backend/utils/adt/acl.c index 11f4dc52bf0..a868c6c1c05 100644 --- a/src/backend/utils/adt/acl.c +++ b/src/backend/utils/adt/acl.c @@ -8,7 +8,7 @@ * * * IDENTIFICATION - * $Header: /cvsroot/pgsql/src/backend/utils/adt/acl.c,v 1.65 2001/10/25 05:49:43 momjian Exp $ + * $Header: /cvsroot/pgsql/src/backend/utils/adt/acl.c,v 1.66 2001/11/16 23:30:35 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -385,7 +385,9 @@ acldefault(const char *relname, AclId ownerid) aip = ACL_DAT(acl); aip[0].ai_idtype = ACL_IDTYPE_WORLD; aip[0].ai_id = ACL_ID_WORLD; - aip[0].ai_mode = IsSystemRelationName(relname) ? ACL_SELECT : ACL_WORLD_DEFAULT; + aip[0].ai_mode = (IsSystemRelationName(relname) && + !IsToastRelationName(relname)) ? ACL_SELECT + : ACL_WORLD_DEFAULT; aip[1].ai_idtype = ACL_IDTYPE_UID; aip[1].ai_id = ownerid; aip[1].ai_mode = ACL_OWNER_DEFAULT; |