[PATCH] Cleanup: unify checks for catalog modification

From: Marti Raudsepp <marti(at)juffo(dot)org>
To: pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: [PATCH] Cleanup: unify checks for catalog modification
Date: 2014-10-14 22:56:27
Message-ID: CABRT9RB3AiULxzeTUZ-c-wpYdvfMGbxG4fPne38vtRNdm86Svw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi list,

I happened to notice that there are no less than 14 places in the code
that check whether a relation is a system catalog and throwing the
error "permission denied: "foo" is a system catalog"

The attached patch factors all of those into a single
ForbidSystemTableMods() function. Is this considered an improvement?
Should I add it to CommitFest?

Regards,
Marti

Attachment Content-Type Size
0001-Cleanup-unify-checks-for-catalog-modification.patch binary/octet-stream 10.0 KB

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Andrew Dunstan 2014-10-14 22:59:50 Re: narwhal and PGDLLIMPORT
Previous Message Dave Page 2014-10-14 22:44:55 Re: narwhal and PGDLLIMPORT