mirror of
https://git.postgresql.org/git/postgresql.git
synced 2025-01-30 19:00:29 +08:00
Make error message of pageinspect more consistent for raw page inputs
There is a copy-paste error from bt_page_items() which got into bt_page_items_bytea(). A second message in get_raw_page_internal() was inconsistent with all the other sub-modules. Author: Ashutosh Sharma Discussion: https://postgr.es/m/CAE9k0PnZuZ3PVXSyQY91-53E8JKFcaSyknFqqU43r9MabKSYZA@mail.gmail.com
This commit is contained in:
parent
9f7ba88aa4
commit
59eb12c9c5
@ -429,7 +429,7 @@ bt_page_items_bytea(PG_FUNCTION_ARGS)
|
||||
if (!superuser())
|
||||
ereport(ERROR,
|
||||
(errcode(ERRCODE_INSUFFICIENT_PRIVILEGE),
|
||||
(errmsg("must be superuser to use pageinspect functions"))));
|
||||
(errmsg("must be superuser to use raw page functions"))));
|
||||
|
||||
if (SRF_IS_FIRSTCALL())
|
||||
{
|
||||
|
@ -102,7 +102,7 @@ get_raw_page_internal(text *relname, ForkNumber forknum, BlockNumber blkno)
|
||||
if (!superuser())
|
||||
ereport(ERROR,
|
||||
(errcode(ERRCODE_INSUFFICIENT_PRIVILEGE),
|
||||
(errmsg("must be superuser to use raw functions"))));
|
||||
(errmsg("must be superuser to use raw page functions"))));
|
||||
|
||||
relrv = makeRangeVarFromNameList(textToQualifiedNameList(relname));
|
||||
rel = relation_openrv(relrv, AccessShareLock);
|
||||
|
Loading…
Reference in New Issue
Block a user