Обсуждение: pg_control_init() bug
Hello,
I noticed that pg_control_init() is failing an assertion on 13devel:
TRAP: FailedAssertion("(atti->attalign) == 's'", File: "heaptuple.c", Line: 160)
postgres: bossartn postgres [local] SELECT(ExceptionalCondition+0x55)[0x8e02b5]
postgres: bossartn postgres [local] SELECT(heap_compute_data_size+0x224)[0x486eb4]
postgres: bossartn postgres [local] SELECT(heap_form_tuple+0x82)[0x488262]
postgres: bossartn postgres [local] SELECT(pg_control_init+0x259)[0x902ca9]
postgres: bossartn postgres [local] SELECT(ExecMakeTableFunctionResult+0x345)[0x656a65]
postgres: bossartn postgres [local] SELECT[0x667e03]
postgres: bossartn postgres [local] SELECT(ExecScan+0x3ab)[0x6572db]
postgres: bossartn postgres [local] SELECT(standard_ExecutorRun+0x137)[0x64f097]
postgres: bossartn postgres [local] SELECT[0x7c5d8b]
postgres: bossartn postgres [local] SELECT(PortalRun+0x1d1)[0x7c71c1]
postgres: bossartn postgres [local] SELECT[0x7c34d1]
postgres: bossartn postgres [local] SELECT(PostgresMain+0x624)[0x7c4aa4]
postgres: bossartn postgres [local] SELECT[0x74109a]
postgres: bossartn postgres [local] SELECT(main+0x440)[0x69f220]
/lib64/libc.so.6(__libc_start_main+0xfd)[0x7fbb78309d1d]
postgres: bossartn postgres [local] SELECT[0x47b039]
2019-12-10 20:02:03.100 UTC [20859] LOG: server process (PID 20868) was terminated by signal 6: Aborted
2019-12-10 20:02:03.100 UTC [20859] DETAIL: Failed process was running: SELECT * FROM pg_control_init();
2019-12-10 20:02:03.100 UTC [20859] LOG: terminating any other active server processes
The attached patch seems to clear this up. I think this was missed in
2e4db241.
Nathan
Вложения
"Bossart, Nathan" <bossartn@amazon.com> writes:
> I noticed that pg_control_init() is failing an assertion on 13devel:
Hmm, yeah. In a non-assert build I get
regression=# select * from pg_control_init();
ERROR: function return row and query-specified return row do not match
DETAIL: Returned row contains 12 attributes, but query expects 11.
> The attached patch seems to clear this up. I think this was missed in
> 2e4db241.
Evidently. Thanks for the report!
regards, tom lane
On Tue, Dec 10, 2019 at 05:46:48PM -0500, Tom Lane wrote:
> "Bossart, Nathan" <bossartn@amazon.com> writes:
> > I noticed that pg_control_init() is failing an assertion on 13devel:
>
> Hmm, yeah. In a non-assert build I get
>
> regression=# select * from pg_control_init();
> ERROR: function return row and query-specified return row do not match
> DETAIL: Returned row contains 12 attributes, but query expects 11.
>
> > The attached patch seems to clear this up. I think this was missed in
> > 2e4db241.
>
> Evidently. Thanks for the report!
FYI, this has been applied:
Fix tuple column count in pg_control_init().
Oversight in commit 2e4db241b.
Nathan Bossart
Discussion: https://postgr.es/m/1B616360-396A-4482-AA28-375566C86160@amazon.com
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/8729fa72483f8a9acf299508bb2cbae1aa9a29b8
Modified Files
--------------
src/backend/utils/misc/pg_controldata.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--
Bruce Momjian <bruce@momjian.us> http://momjian.us
EnterpriseDB http://enterprisedb.com
+ As you are, so once was I. As I am, so you will be. +
+ Ancient Roman grave inscription +