pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
pgsql: Plug memory leak in index_get_partition
3+ messages / 1 participants
[nested] [flat]

* pgsql: Plug memory leak in index_get_partition
@ 2020-11-07 01:53  Alvaro Herrera <alvherre@alvh.no-ip.org>
  0 siblings, 0 replies; 3+ messages in thread

From: Alvaro Herrera @ 2020-11-07 01:53 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Plug memory leak in index_get_partition

The list of indexes was being leaked when asked for an index that
doesn't have an index partition in the table partition.  Not a common
case admittedly --and in most cases where it occurs, caller throws an
error anyway-- but worth fixing for cleanliness and in case any
third-party code is calling this function.

While at it, remove use of lfirst_oid() to obtain a value we already
have.

Author: Justin Pryzby <pryzby@telsasoft.com>
Reviewed-by: Michael Paquier <michael@paquier.xyz>
Discussion: https://postgr.es/m/20201105203606.GF22691@telsasoft.com

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/623644f02cbde7ad3812b201bd36213a206c3341

Modified Files
--------------
src/backend/catalog/partition.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)



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

* pgsql: Plug memory leak in index_get_partition
@ 2020-11-07 01:53  Alvaro Herrera <alvherre@alvh.no-ip.org>
  0 siblings, 0 replies; 3+ messages in thread

From: Alvaro Herrera @ 2020-11-07 01:53 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Plug memory leak in index_get_partition

The list of indexes was being leaked when asked for an index that
doesn't have an index partition in the table partition.  Not a common
case admittedly --and in most cases where it occurs, caller throws an
error anyway-- but worth fixing for cleanliness and in case any
third-party code is calling this function.

While at it, remove use of lfirst_oid() to obtain a value we already
have.

Author: Justin Pryzby <pryzby@telsasoft.com>
Reviewed-by: Michael Paquier <michael@paquier.xyz>
Discussion: https://postgr.es/m/20201105203606.GF22691@telsasoft.com

Branch
------
REL_12_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/8ad6a0c1bb1c5a041cadfed713ef6bcabd0955ab

Modified Files
--------------
src/backend/catalog/partition.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)



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

* pgsql: Plug memory leak in index_get_partition
@ 2020-11-07 01:53  Alvaro Herrera <alvherre@alvh.no-ip.org>
  0 siblings, 0 replies; 3+ messages in thread

From: Alvaro Herrera @ 2020-11-07 01:53 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Plug memory leak in index_get_partition

The list of indexes was being leaked when asked for an index that
doesn't have an index partition in the table partition.  Not a common
case admittedly --and in most cases where it occurs, caller throws an
error anyway-- but worth fixing for cleanliness and in case any
third-party code is calling this function.

While at it, remove use of lfirst_oid() to obtain a value we already
have.

Author: Justin Pryzby <pryzby@telsasoft.com>
Reviewed-by: Michael Paquier <michael@paquier.xyz>
Discussion: https://postgr.es/m/20201105203606.GF22691@telsasoft.com

Branch
------
REL_13_STABLE

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

Modified Files
--------------
src/backend/catalog/partition.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)



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


end of thread, other threads:[~2020-11-07 01:53 UTC | newest]

Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2020-11-07 01:53 pgsql: Plug memory leak in index_get_partition Alvaro Herrera <alvherre@alvh.no-ip.org>
2020-11-07 01:53 pgsql: Plug memory leak in index_get_partition Alvaro Herrera <alvherre@alvh.no-ip.org>
2020-11-07 01:53 pgsql: Plug memory leak in index_get_partition Alvaro Herrera <alvherre@alvh.no-ip.org>

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