pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
pgsql: Fix EXIT out of outermost block in plpgsql.
7+ messages / 1 participants
[nested] [flat]

* pgsql: Fix EXIT out of outermost block in plpgsql.
@ 2021-09-13 16:42 Tom Lane <tgl@sss.pgh.pa.us>
  0 siblings, 0 replies; 7+ messages in thread

From: Tom Lane @ 2021-09-13 16:42 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Fix EXIT out of outermost block in plpgsql.

Ordinarily, using EXIT this way would draw "control reached end of
function without RETURN".  However, if the function is one where we
don't require an explicit RETURN (such as a DO block), that should
not happen.  It did anyway, because add_dummy_return() neglected to
account for the case.

Per report from Herwig Goemans.  Back-patch to all supported branches.

Discussion: https://postgr.es/m/868ae948-e3ca-c7ec-95a6-83cfc08ef750@gmail.com

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/1bf2518dd67be58b207979a66db7bb7c94b93a62

Modified Files
--------------
src/pl/plpgsql/src/expected/plpgsql_control.out | 11 +++++++++++
src/pl/plpgsql/src/pl_comp.c                    |  6 ++++--
src/pl/plpgsql/src/sql/plpgsql_control.sql      | 12 ++++++++++++
3 files changed, 27 insertions(+), 2 deletions(-)



^ permalink  raw  reply  [nested|flat] 7+ messages in thread

* pgsql: Fix EXIT out of outermost block in plpgsql.
@ 2021-09-13 16:42 Tom Lane <tgl@sss.pgh.pa.us>
  0 siblings, 0 replies; 7+ messages in thread

From: Tom Lane @ 2021-09-13 16:42 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Fix EXIT out of outermost block in plpgsql.

Ordinarily, using EXIT this way would draw "control reached end of
function without RETURN".  However, if the function is one where we
don't require an explicit RETURN (such as a DO block), that should
not happen.  It did anyway, because add_dummy_return() neglected to
account for the case.

Per report from Herwig Goemans.  Back-patch to all supported branches.

Discussion: https://postgr.es/m/868ae948-e3ca-c7ec-95a6-83cfc08ef750@gmail.com

Branch
------
REL_14_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/4ffd3fe4d6ccc9ff36271e5a21ea3b065621b982

Modified Files
--------------
src/pl/plpgsql/src/expected/plpgsql_control.out | 11 +++++++++++
src/pl/plpgsql/src/pl_comp.c                    |  6 ++++--
src/pl/plpgsql/src/sql/plpgsql_control.sql      | 12 ++++++++++++
3 files changed, 27 insertions(+), 2 deletions(-)



^ permalink  raw  reply  [nested|flat] 7+ messages in thread

* pgsql: Fix EXIT out of outermost block in plpgsql.
@ 2021-09-13 16:42 Tom Lane <tgl@sss.pgh.pa.us>
  0 siblings, 0 replies; 7+ messages in thread

From: Tom Lane @ 2021-09-13 16:42 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Fix EXIT out of outermost block in plpgsql.

Ordinarily, using EXIT this way would draw "control reached end of
function without RETURN".  However, if the function is one where we
don't require an explicit RETURN (such as a DO block), that should
not happen.  It did anyway, because add_dummy_return() neglected to
account for the case.

Per report from Herwig Goemans.  Back-patch to all supported branches.

Discussion: https://postgr.es/m/868ae948-e3ca-c7ec-95a6-83cfc08ef750@gmail.com

Branch
------
REL_13_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/745abdd951ab31f3276adbbbf67bbc3b7dac0923

Modified Files
--------------
src/pl/plpgsql/src/expected/plpgsql_control.out | 11 +++++++++++
src/pl/plpgsql/src/pl_comp.c                    |  6 ++++--
src/pl/plpgsql/src/sql/plpgsql_control.sql      | 12 ++++++++++++
3 files changed, 27 insertions(+), 2 deletions(-)



^ permalink  raw  reply  [nested|flat] 7+ messages in thread

* pgsql: Fix EXIT out of outermost block in plpgsql.
@ 2021-09-13 16:42 Tom Lane <tgl@sss.pgh.pa.us>
  0 siblings, 0 replies; 7+ messages in thread

From: Tom Lane @ 2021-09-13 16:42 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Fix EXIT out of outermost block in plpgsql.

Ordinarily, using EXIT this way would draw "control reached end of
function without RETURN".  However, if the function is one where we
don't require an explicit RETURN (such as a DO block), that should
not happen.  It did anyway, because add_dummy_return() neglected to
account for the case.

Per report from Herwig Goemans.  Back-patch to all supported branches.

Discussion: https://postgr.es/m/868ae948-e3ca-c7ec-95a6-83cfc08ef750@gmail.com

Branch
------
REL_12_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/b1de90699e73a081ac450420b7d4f3fd1d49981b

Modified Files
--------------
src/pl/plpgsql/src/expected/plpgsql_control.out | 11 +++++++++++
src/pl/plpgsql/src/pl_comp.c                    |  6 ++++--
src/pl/plpgsql/src/sql/plpgsql_control.sql      | 12 ++++++++++++
3 files changed, 27 insertions(+), 2 deletions(-)



^ permalink  raw  reply  [nested|flat] 7+ messages in thread

* pgsql: Fix EXIT out of outermost block in plpgsql.
@ 2021-09-13 16:42 Tom Lane <tgl@sss.pgh.pa.us>
  0 siblings, 0 replies; 7+ messages in thread

From: Tom Lane @ 2021-09-13 16:42 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Fix EXIT out of outermost block in plpgsql.

Ordinarily, using EXIT this way would draw "control reached end of
function without RETURN".  However, if the function is one where we
don't require an explicit RETURN (such as a DO block), that should
not happen.  It did anyway, because add_dummy_return() neglected to
account for the case.

Per report from Herwig Goemans.  Back-patch to all supported branches.

Discussion: https://postgr.es/m/868ae948-e3ca-c7ec-95a6-83cfc08ef750@gmail.com

Branch
------
REL_11_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/bdd6ce48d0356fbfaa0fe4a1fee20068f99abb70

Modified Files
--------------
src/pl/plpgsql/src/expected/plpgsql_control.out | 11 +++++++++++
src/pl/plpgsql/src/pl_comp.c                    |  6 ++++--
src/pl/plpgsql/src/sql/plpgsql_control.sql      | 12 ++++++++++++
3 files changed, 27 insertions(+), 2 deletions(-)



^ permalink  raw  reply  [nested|flat] 7+ messages in thread

* pgsql: Fix EXIT out of outermost block in plpgsql.
@ 2021-09-13 16:42 Tom Lane <tgl@sss.pgh.pa.us>
  0 siblings, 0 replies; 7+ messages in thread

From: Tom Lane @ 2021-09-13 16:42 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Fix EXIT out of outermost block in plpgsql.

Ordinarily, using EXIT this way would draw "control reached end of
function without RETURN".  However, if the function is one where we
don't require an explicit RETURN (such as a DO block), that should
not happen.  It did anyway, because add_dummy_return() neglected to
account for the case.

Per report from Herwig Goemans.  Back-patch to all supported branches.

Discussion: https://postgr.es/m/868ae948-e3ca-c7ec-95a6-83cfc08ef750@gmail.com

Branch
------
REL_10_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/fe70ec9078a5f20a2bd21687ba31cb351147a113

Modified Files
--------------
src/pl/plpgsql/src/pl_comp.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)



^ permalink  raw  reply  [nested|flat] 7+ messages in thread

* pgsql: Fix EXIT out of outermost block in plpgsql.
@ 2021-09-13 16:42 Tom Lane <tgl@sss.pgh.pa.us>
  0 siblings, 0 replies; 7+ messages in thread

From: Tom Lane @ 2021-09-13 16:42 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Fix EXIT out of outermost block in plpgsql.

Ordinarily, using EXIT this way would draw "control reached end of
function without RETURN".  However, if the function is one where we
don't require an explicit RETURN (such as a DO block), that should
not happen.  It did anyway, because add_dummy_return() neglected to
account for the case.

Per report from Herwig Goemans.  Back-patch to all supported branches.

Discussion: https://postgr.es/m/868ae948-e3ca-c7ec-95a6-83cfc08ef750@gmail.com

Branch
------
REL9_6_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/a460f7eb3d5ab269fa72f0b4350e561ec158b0e7

Modified Files
--------------
src/pl/plpgsql/src/pl_comp.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)



^ permalink  raw  reply  [nested|flat] 7+ messages in thread


end of thread, other threads:[~2021-09-13 16:42 UTC | newest]

Thread overview: 7+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2021-09-13 16:42 pgsql: Fix EXIT out of outermost block in plpgsql. Tom Lane <tgl@sss.pgh.pa.us>
2021-09-13 16:42 pgsql: Fix EXIT out of outermost block in plpgsql. Tom Lane <tgl@sss.pgh.pa.us>
2021-09-13 16:42 pgsql: Fix EXIT out of outermost block in plpgsql. Tom Lane <tgl@sss.pgh.pa.us>
2021-09-13 16:42 pgsql: Fix EXIT out of outermost block in plpgsql. Tom Lane <tgl@sss.pgh.pa.us>
2021-09-13 16:42 pgsql: Fix EXIT out of outermost block in plpgsql. Tom Lane <tgl@sss.pgh.pa.us>
2021-09-13 16:42 pgsql: Fix EXIT out of outermost block in plpgsql. Tom Lane <tgl@sss.pgh.pa.us>
2021-09-13 16:42 pgsql: Fix EXIT out of outermost block in plpgsql. Tom Lane <tgl@sss.pgh.pa.us>

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox