]> git.ipfire.org Git - thirdparty/postgresql.git/commit
ecpg: Reject multiple header items in GET/SET DESCRIPTOR
authorFujii Masao <fujii@postgresql.org>
Mon, 8 Jun 2026 08:11:12 +0000 (17:11 +0900)
committerFujii Masao <fujii@postgresql.org>
Mon, 8 Jun 2026 08:14:20 +0000 (17:14 +0900)
commit9e8fd9f7ab56965dfe012d6be1df152ea8f62aec
treedef1339e81d4e4ecbd8570324d6d94e21ed685e7
parenta4ca91ea18916c66fa3539c2fd19d8ba571ce7e8
ecpg: Reject multiple header items in GET/SET DESCRIPTOR

Previously, ecpg accepted multiple descriptor header items in GET DESCRIPTOR
and SET DESCRIPTOR, but generated broken C code when they were used.
Although the grammar allowed this syntax, the implementation did not actually
support it.

This commit tightens the ecpg grammar so the header form of GET/SET DESCRIPTOR
accepts only a single header item, matching the implementation and preventing
generation of broken C code.

Also update the documentation synopsis accordingly.

Backpatch to all supported versions.

Author: Masashi Kamura <kamura.masashi@fujitsu.com>
Reviewed-by: Hayato Kuroda <kuroda.hayato@fujitsu.com>
Reviewed-by: Lakshmi G <lakshmigcdac@gmail.com>
Reviewed-by: Fujii Masao <masao.fujii@gmail.com>
Discussion: https://postgr.es/m/OS9PR01MB13174AD7D1829D0644B6BB90E9447A@OS9PR01MB13174.jpnprd01.prod.outlook.com
Backpatch-through: 14
doc/src/sgml/ecpg.sgml
src/interfaces/ecpg/preproc/ecpg.trailer