pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
pgsql: Avoid crash in rare case of concurrent DROP
7+ messages / 1 participants
[nested] [flat]

* pgsql: Avoid crash in rare case of concurrent DROP
@ 2021-11-05 15:33  Alvaro Herrera <alvherre@alvh.no-ip.org>
  0 siblings, 0 replies; 7+ messages in thread

From: Alvaro Herrera @ 2021-11-05 15:33 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Avoid crash in rare case of concurrent DROP

When a role being dropped contains is referenced by catalog objects that
are concurrently also being dropped, a crash can result while trying to
construct the string that describes the objects.  Suppress that by
ignoring objects whose descriptions are returned as NULL.

The majority of relevant codesites were already cautious about this
already; we had just missed a couple.

This is an old bug, so backpatch all the way back.

Reported-by: Alexander Lakhin <exclusion@gmail.com>
Discussion: https://postgr.es/m/17126-21887f04508cb5c8@postgresql.org

Branch
------
REL_11_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/92224e470c830e73636de20689690f28037cd019

Modified Files
--------------
src/backend/catalog/dependency.c  | 31 ++++++++++++++++++++-----------
src/backend/catalog/pg_shdepend.c |  6 ++++++
2 files changed, 26 insertions(+), 11 deletions(-)



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

* pgsql: Avoid crash in rare case of concurrent DROP
@ 2021-11-05 15:33  Alvaro Herrera <alvherre@alvh.no-ip.org>
  0 siblings, 0 replies; 7+ messages in thread

From: Alvaro Herrera @ 2021-11-05 15:33 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Avoid crash in rare case of concurrent DROP

When a role being dropped contains is referenced by catalog objects that
are concurrently also being dropped, a crash can result while trying to
construct the string that describes the objects.  Suppress that by
ignoring objects whose descriptions are returned as NULL.

The majority of relevant codesites were already cautious about this
already; we had just missed a couple.

This is an old bug, so backpatch all the way back.

Reported-by: Alexander Lakhin <exclusion@gmail.com>
Discussion: https://postgr.es/m/17126-21887f04508cb5c8@postgresql.org

Branch
------
REL_10_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/58b600f64bfb80ca6daf6d9f27af9c3105e13500

Modified Files
--------------
src/backend/catalog/dependency.c  | 31 ++++++++++++++++++++-----------
src/backend/catalog/pg_shdepend.c |  6 ++++++
2 files changed, 26 insertions(+), 11 deletions(-)



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

* pgsql: Avoid crash in rare case of concurrent DROP
@ 2021-11-05 15:33  Alvaro Herrera <alvherre@alvh.no-ip.org>
  0 siblings, 0 replies; 7+ messages in thread

From: Alvaro Herrera @ 2021-11-05 15:33 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Avoid crash in rare case of concurrent DROP

When a role being dropped contains is referenced by catalog objects that
are concurrently also being dropped, a crash can result while trying to
construct the string that describes the objects.  Suppress that by
ignoring objects whose descriptions are returned as NULL.

The majority of relevant codesites were already cautious about this
already; we had just missed a couple.

This is an old bug, so backpatch all the way back.

Reported-by: Alexander Lakhin <exclusion@gmail.com>
Discussion: https://postgr.es/m/17126-21887f04508cb5c8@postgresql.org

Branch
------
REL_13_STABLE

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

Modified Files
--------------
src/backend/catalog/dependency.c  | 31 ++++++++++++++++++++-----------
src/backend/catalog/pg_shdepend.c |  6 ++++++
2 files changed, 26 insertions(+), 11 deletions(-)



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

* pgsql: Avoid crash in rare case of concurrent DROP
@ 2021-11-05 15:33  Alvaro Herrera <alvherre@alvh.no-ip.org>
  0 siblings, 0 replies; 7+ messages in thread

From: Alvaro Herrera @ 2021-11-05 15:33 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Avoid crash in rare case of concurrent DROP

When a role being dropped contains is referenced by catalog objects that
are concurrently also being dropped, a crash can result while trying to
construct the string that describes the objects.  Suppress that by
ignoring objects whose descriptions are returned as NULL.

The majority of relevant codesites were already cautious about this
already; we had just missed a couple.

This is an old bug, so backpatch all the way back.

Reported-by: Alexander Lakhin <exclusion@gmail.com>
Discussion: https://postgr.es/m/17126-21887f04508cb5c8@postgresql.org

Branch
------
REL_12_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/3eff168a29ca6d737611e8608504537d4ff18d50

Modified Files
--------------
src/backend/catalog/dependency.c  | 31 ++++++++++++++++++++-----------
src/backend/catalog/pg_shdepend.c |  6 ++++++
2 files changed, 26 insertions(+), 11 deletions(-)



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

* pgsql: Avoid crash in rare case of concurrent DROP
@ 2021-11-05 15:33  Alvaro Herrera <alvherre@alvh.no-ip.org>
  0 siblings, 0 replies; 7+ messages in thread

From: Alvaro Herrera @ 2021-11-05 15:33 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Avoid crash in rare case of concurrent DROP

When a role being dropped contains is referenced by catalog objects that
are concurrently also being dropped, a crash can result while trying to
construct the string that describes the objects.  Suppress that by
ignoring objects whose descriptions are returned as NULL.

The majority of relevant codesites were already cautious about this
already; we had just missed a couple.

This is an old bug, so backpatch all the way back.

Reported-by: Alexander Lakhin <exclusion@gmail.com>
Discussion: https://postgr.es/m/17126-21887f04508cb5c8@postgresql.org

Branch
------
master

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

Modified Files
--------------
src/backend/catalog/dependency.c  | 31 ++++++++++++++++++++-----------
src/backend/catalog/pg_shdepend.c |  6 ++++++
2 files changed, 26 insertions(+), 11 deletions(-)



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

* pgsql: Avoid crash in rare case of concurrent DROP
@ 2021-11-05 15:33  Alvaro Herrera <alvherre@alvh.no-ip.org>
  0 siblings, 0 replies; 7+ messages in thread

From: Alvaro Herrera @ 2021-11-05 15:33 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Avoid crash in rare case of concurrent DROP

When a role being dropped contains is referenced by catalog objects that
are concurrently also being dropped, a crash can result while trying to
construct the string that describes the objects.  Suppress that by
ignoring objects whose descriptions are returned as NULL.

The majority of relevant codesites were already cautious about this
already; we had just missed a couple.

This is an old bug, so backpatch all the way back.

Reported-by: Alexander Lakhin <exclusion@gmail.com>
Discussion: https://postgr.es/m/17126-21887f04508cb5c8@postgresql.org

Branch
------
REL_14_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/02e20bb2dcaa523782a8fe7de1c2ddfefaeff033

Modified Files
--------------
src/backend/catalog/dependency.c  | 31 ++++++++++++++++++++-----------
src/backend/catalog/pg_shdepend.c |  6 ++++++
2 files changed, 26 insertions(+), 11 deletions(-)



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

* pgsql: Avoid crash in rare case of concurrent DROP
@ 2021-11-05 15:33  Alvaro Herrera <alvherre@alvh.no-ip.org>
  0 siblings, 0 replies; 7+ messages in thread

From: Alvaro Herrera @ 2021-11-05 15:33 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Avoid crash in rare case of concurrent DROP

When a role being dropped contains is referenced by catalog objects that
are concurrently also being dropped, a crash can result while trying to
construct the string that describes the objects.  Suppress that by
ignoring objects whose descriptions are returned as NULL.

The majority of relevant codesites were already cautious about this
already; we had just missed a couple.

This is an old bug, so backpatch all the way back.

Reported-by: Alexander Lakhin <exclusion@gmail.com>
Discussion: https://postgr.es/m/17126-21887f04508cb5c8@postgresql.org

Branch
------
REL9_6_STABLE

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

Modified Files
--------------
src/backend/catalog/dependency.c  | 31 ++++++++++++++++++++-----------
src/backend/catalog/pg_shdepend.c |  6 ++++++
2 files changed, 26 insertions(+), 11 deletions(-)



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


end of thread, other threads:[~2021-11-05 15:33 UTC | newest]

Thread overview: 7+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2021-11-05 15:33 pgsql: Avoid crash in rare case of concurrent DROP Alvaro Herrera <alvherre@alvh.no-ip.org>
2021-11-05 15:33 pgsql: Avoid crash in rare case of concurrent DROP Alvaro Herrera <alvherre@alvh.no-ip.org>
2021-11-05 15:33 pgsql: Avoid crash in rare case of concurrent DROP Alvaro Herrera <alvherre@alvh.no-ip.org>
2021-11-05 15:33 pgsql: Avoid crash in rare case of concurrent DROP Alvaro Herrera <alvherre@alvh.no-ip.org>
2021-11-05 15:33 pgsql: Avoid crash in rare case of concurrent DROP Alvaro Herrera <alvherre@alvh.no-ip.org>
2021-11-05 15:33 pgsql: Avoid crash in rare case of concurrent DROP Alvaro Herrera <alvherre@alvh.no-ip.org>
2021-11-05 15:33 pgsql: Avoid crash in rare case of concurrent DROP 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