Re: Detect double-release of spinlock

Tom Lane <tgl@sss.pgh.pa.us>

From: Tom Lane <tgl@sss.pgh.pa.us>
To: Andres Freund <andres@anarazel.de>
Cc: Heikki Linnakangas <hlinnaka@iki.fi>, pgsql-hackers@postgresql.org
Date: 2024-07-29T17:57:02Z
Lists: pgsql-hackers
Andres Freund <andres@anarazel.de> writes:
> However, I still don't think it's a problem to assert that the lock is held in
> in the unlock "routine". As mentioned before, the spinlock implementation
> itself has never followed the "just straight line code" rule that users of
> spinlocks are supposed to follow.

Yeah, that's fair.

			regards, tom lane



Commits

  1. Fix double-release of spinlock

  2. Move cancel key generation to after forking the backend