pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
pgsql: Cancel CV sleep during subtransaction abort.
2+ messages / 1 participants
[nested] [flat]

* pgsql: Cancel CV sleep during subtransaction abort.
@ 2017-12-21 14:25 Robert Haas <rhaas@postgresql.org>
  0 siblings, 0 replies; 2+ messages in thread

From: Robert Haas @ 2017-12-21 14:25 UTC (permalink / raw)
  To: pgsql-committers

Cancel CV sleep during subtransaction abort.

Generally, error recovery paths that need to do things like
LWLockReleaseAll and pgstat_report_wait_end also need to call
ConditionVariableCancelSleep, but AbortSubTransaction was missed.

Since subtransaction abort might destroy up the DSM segment that
contains the ConditionVariable stored in cv_sleep_target, this
can result in a crash for anything using condition variables.

Reported and diagnosed by Andres Freund.

Discussion: http://postgr.es/m/20171221110048.rxk6464azzl5t2fi@alap3.anarazel.de

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/59d1e2b95a826869e2789ffe01e9e552148eefde

Modified Files
--------------
src/backend/access/transam/xact.c | 3 +++
1 file changed, 3 insertions(+)



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

* pgsql: Cancel CV sleep during subtransaction abort.
@ 2017-12-21 14:25 Robert Haas <rhaas@postgresql.org>
  0 siblings, 0 replies; 2+ messages in thread

From: Robert Haas @ 2017-12-21 14:25 UTC (permalink / raw)
  To: pgsql-committers

Cancel CV sleep during subtransaction abort.

Generally, error recovery paths that need to do things like
LWLockReleaseAll and pgstat_report_wait_end also need to call
ConditionVariableCancelSleep, but AbortSubTransaction was missed.

Since subtransaction abort might destroy up the DSM segment that
contains the ConditionVariable stored in cv_sleep_target, this
can result in a crash for anything using condition variables.

Reported and diagnosed by Andres Freund.

Discussion: http://postgr.es/m/20171221110048.rxk6464azzl5t2fi@alap3.anarazel.de

Branch
------
REL_10_STABLE

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

Modified Files
--------------
src/backend/access/transam/xact.c | 3 +++
1 file changed, 3 insertions(+)



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


end of thread, other threads:[~2017-12-21 14:25 UTC | newest]

Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2017-12-21 14:25 pgsql: Cancel CV sleep during subtransaction abort. Robert Haas <rhaas@postgresql.org>
2017-12-21 14:25 pgsql: Cancel CV sleep during subtransaction abort. Robert Haas <rhaas@postgresql.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