From: | Tomas Vondra <tomas(dot)vondra(at)postgresql(dot)org> |
---|---|
To: | pgsql-committers(at)lists(dot)postgresql(dot)org |
Subject: | pgsql: Fix lookup error in extended stats ownership check |
Date: | 2021-08-31 16:37:55 |
Message-ID: | E1mL6ln-0003R8-MR@gemulon.postgresql.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-committers |
Fix lookup error in extended stats ownership check
When an ownership check on extended statistics object failed, the code
was calling aclcheck_error_type to report the failure, which is clearly
wrong, resulting in cache lookup errors. Fix by calling aclcheck_error.
This issue exists since the introduction of extended statistics, so
backpatch all the way back to PostgreSQL 10. It went unnoticed because
there were no tests triggering the error, so add one.
Reported-by: Mark Dilger
Backpatch-through: 10, where extended stats were introduced
Discussion: https://postgr.es/m/1F238937-7CC2-4703-A1B1-6DC225B8978A%40enterprisedb.com
Branch
------
REL_14_STABLE
Details
-------
https://git.postgresql.org/pg/commitdiff/a371a5ba349d9c39e7754f7d0f195ac46ee87b3f
Modified Files
--------------
src/backend/catalog/objectaddress.c | 3 ++-
src/test/regress/expected/stats_ext.out | 11 +++++++++++
src/test/regress/sql/stats_ext.sql | 9 +++++++++
3 files changed, 22 insertions(+), 1 deletion(-)
From | Date | Subject | |
---|---|---|---|
Next Message | Tomas Vondra | 2021-08-31 16:39:56 | pgsql: Fix lookup error in extended stats ownership check |
Previous Message | Tomas Vondra | 2021-08-31 16:35:49 | pgsql: Fix lookup error in extended stats ownership check |