From 9333608c3ae04de3052147fedf669cc1d73b11eb Mon Sep 17 00:00:00 2001 From: Andreas Karlsson Date: Thu, 20 Feb 2025 17:30:24 +0100 Subject: [PATCH] PG-1349 Remove call to LWLockRelease() in PG_CATCH() It is not safe to release an LWLock in a catch section without incrementing InterruptHoldoffCount so let's isntead simply not release the lock here. --- pg_stat_monitor.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/pg_stat_monitor.c b/pg_stat_monitor.c index 9109e98..3f2d3c9 100644 --- a/pg_stat_monitor.c +++ b/pg_stat_monitor.c @@ -2018,8 +2018,6 @@ pgsm_store(pgsmEntry *entry) } PG_CATCH(); { - pgsm_lock_release(pgsm); - if (DsaPointerIsValid(dsa_query_pointer)) dsa_free(query_dsa_area, dsa_query_pointer); PG_RE_THROW();