git.postgresql.org Git - postgresql.git/commitdiff

git projects / postgresql.git / commitdiff
? search:
summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: ed62d37)
Fix function name in error hint
2021年3月18日 10:17:42 +0000 (11:17 +0100)
2021年3月18日 10:22:20 +0000 (11:22 +0100)
pg_read_file() is the function that's in core, pg_file_read() is in
adminpack. But when using pg_file_read() in adminpack it calls the *C*
level function pg_read_file() in core, which probably threw the original
author off. But the error hint should be about the SQL function.

Reported-By: Sergei Kornilov
Backpatch-through: 11
Discussion: https://postgr.es/m/373021616060475@mail.yandex.ru


diff --git a/src/backend/utils/adt/genfile.c b/src/backend/utils/adt/genfile.c
index 169ddf8d7681365d55d8ac044059dc443b5aec60..7cf9a0efbec127dcb7b4e3d73e9a836bd186509a 100644 (file)
--- a/src/backend/utils/adt/genfile.c
+++ b/src/backend/utils/adt/genfile.c
@@ -251,7 +251,7 @@ pg_read_file(PG_FUNCTION_ARGS)
errmsg("must be superuser to read files with adminpack 1.0"),
/* translator: %s is a SQL function name */
errhint("Consider using %s, which is part of core, instead.",
- "pg_file_read()")));
+ "pg_read_file()")));
/* handle optional arguments */
if (PG_NARGS() >= 3)
This is the main PostgreSQL git repository.
RSS Atom

AltStyle によって変換されたページ (->オリジナル) /