Hide internal error for pg_collation_actual_version(<bad OID>). Instead of an unsightly internal "cache lookup failed" message, just return NULL for bad OIDs, as is the convention for other similar things.
Reported-by: Justin Pryzby <[email protected]> Reviewed-by: Michael Paquier <[email protected]> Discussion: https://postgr.es/m/20210117215940.GE8560%40telsasoft.com Branch ------ master Details ------- https://git.postgresql.org/pg/commitdiff/0fb0a0503bfc125764c8dba4f515058145dc7f8b Modified Files -------------- src/backend/catalog/index.c | 5 +++-- src/backend/catalog/pg_depend.c | 3 ++- src/backend/commands/collationcmds.c | 2 +- src/backend/utils/adt/pg_locale.c | 9 +++++++-- src/include/utils/pg_locale.h | 2 +- src/test/regress/expected/collate.icu.utf8.out | 14 ++++++++++++++ src/test/regress/sql/collate.icu.utf8.sql | 5 +++++ 7 files changed, 33 insertions(+), 7 deletions(-)
