Nothing is to be gained from using pgrepack outside of REPACK (CONCURRENTLY), and it leads to assertion failures in assertion-enabled builds, and to crashes due to bogus memory lifetime in production builds. Reject attempts to do that with a clean error report. Clean up the nearby code a tad while at it. The only functional changes in that are that the output_writer_private context is allocated and partially filled by the pgrepack output plugin; and that ->relid therein is now always present (rather than only in assertion-enabled builds). Other than that it's just minor code rearrangement and added comments. Author: Álvaro Herrera <alvherre@kurilemu.de> Reported-by: Nikita Kalinin <n.kalinin@postgrespro.ru> Suggested-by: Zhijie Hou <houzj.fnst@fujitsu.com> Reviewed-by: Antonin Houska <ah@cybertec.at> (older version) Reviewed-by: Srinath Reddy Sadipiralla <srinath2133@gmail.com> (older version) Discussion: https://postgr.es/m/19500-38a02529a69353a5@postgresql.org
PostgreSQL Database Management System
This directory contains the source code distribution of the PostgreSQL database management system.
PostgreSQL is an advanced object-relational database management system that supports an extended subset of the SQL standard, including transactions, foreign keys, subqueries, triggers, user-defined types and functions. This distribution also contains C language bindings.
Copyright and license information can be found in the file COPYRIGHT.
General documentation about this version of PostgreSQL can be found at https://www.postgresql.org/docs/devel/. In particular, information about building PostgreSQL from the source code can be found at https://www.postgresql.org/docs/devel/installation.html.
The latest version of this software, and related software, may be obtained at https://www.postgresql.org/download/. For more information look at our web site located at https://www.postgresql.org/.