pgsql: Tighten up error recovery for fast-path locking. - Mailing list pgsql-committers

From Robert Haas
Subject pgsql: Tighten up error recovery for fast-path locking.
Date
Msg-id E1SKWhV-0001Gb-LV@gemulon.postgresql.org
Whole thread Raw
List pgsql-committers
Tighten up error recovery for fast-path locking.

The previous code could cause a backend crash after BEGIN; SAVEPOINT a;
LOCK TABLE foo (interrupted by ^C or statement timeout); ROLLBACK TO
SAVEPOINT a; LOCK TABLE foo, and might have leaked strong-lock counts
in other situations.

Report by Zoltán Böszörményi; patch review by Jeff Davis.

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/53c5b869b464d567c3b8f617201b49a395f437ab

Modified Files
--------------
src/backend/access/transam/xact.c |    4 +-
src/backend/storage/lmgr/README   |    2 +-
src/backend/storage/lmgr/lock.c   |   91 ++++++++++++++++++++++++++++++-------
src/backend/storage/lmgr/proc.c   |   19 +++++---
src/backend/tcop/postgres.c       |    6 +-
src/include/storage/lock.h        |    1 +
src/include/storage/proc.h        |    2 +-
7 files changed, 94 insertions(+), 31 deletions(-)


pgsql-committers by date:

Previous
From: Andrew Dunstan
Date:
Subject: pgsql: Revert recent commit re positional arguments.
Next
From: Robert Haas
Date:
Subject: pgsql: Finish rename of FastPathStrongLocks to FastPathStrongRelationLo