Hi,m

On 2015-04-23 13:51:57 +0900, Michael Paquier wrote:
> After looking at bug #13128, I have been looking at the code around
> LWLockAcquire/Release to see if there are similar issues elsewhere.
> Here are my findings:

Afaics all of these should actually be handled by the paths that release
locks upon error.

> 5) In ReplicationSlotCreate@slot.c, I would think that
> ReplicationSlotAllocationLock should be released when all the locks
> are in use. Similarly, in  ReplicationSlotDropAcquired,
> ReplicationSlotAllocationLock should be released when !fail_softly.
> SaveSlotToPath could also be made safer when a file could not be
> created.

When called via SQL these are released by normal error processing, in
walsender they're released by WalSndErrorCleanup().

Greetings,

Andres Freund


-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

Reply via email to