pgsql: Simplify coding to detach constraints when detaching partition

From: Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org>
To: pgsql-committers(at)lists(dot)postgresql(dot)org
Subject: pgsql: Simplify coding to detach constraints when detaching partition
Date: 2019-01-24 14:27:32
Message-ID: E1gmfye-0003it-LQ@gemulon.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Simplify coding to detach constraints when detaching partition

The original coding was too baroque and led to an use-after-release
mistake, noticed by buildfarm member prion.

Discussion: https://postgr.es/m/21693.1548305934@sss.pgh.pa.us

Branch
------
REL_11_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/71eba83999f3702ee9b909ad2df5cae7ebb58882

Modified Files
--------------
src/backend/commands/tablecmds.c | 18 ++++--------------
1 file changed, 4 insertions(+), 14 deletions(-)

Browse pgsql-committers by date

  From Date Subject
Next Message Alvaro Herrera 2019-01-24 14:28:30 Re: pgsql: Detach constraints when partitions are detached
Previous Message Etsuro Fujita 2019-01-24 07:51:17 pgsql: postgres_fdw: Account for tlist eval costs in estimate_path_cost