Improve error message annotation for GRANT/REVOKE on untrusted PLs.

Tom Lane <tgl@sss.pgh.pa.us>

Commit: 9bc3332372f9992875d80f856fd98999e070fe35
Author: Tom Lane <tgl@sss.pgh.pa.us>
Date: 2016-06-18T23:38:59Z
Releases: 9.6.0
Improve error message annotation for GRANT/REVOKE on untrusted PLs.

The annotation for "ERROR: language "foo" is not trusted" used to say
"HINT: Only superusers can use untrusted languages", which was fairly
poorly thought out.  For one thing, it's not a hint about what to do,
but a statement of fact, which makes it errdetail.  But also, this
fails to clarify things much, because there's a missing step in the
chain of reasoning.  I think it's more useful to say "GRANT and REVOKE
are not allowed on untrusted languages, because only superusers can use
untrusted languages".

It's been like this for a long time, but given the lack of previous
complaints, I don't think this is worth back-patching.

Discussion: <1417.1466289901@sss.pgh.pa.us>

Files

PathChange+/−
src/backend/catalog/aclchk.c modified +2 −1
src/test/regress/expected/privileges.out modified +1 −1