[pgpool-committers: 9848] pgpool: Fix assorted causes of segmentation fault.
Tatsuo Ishii
ishii at sraoss.co.jp
Thu Apr 4 20:38:44 JST 2024
Fix assorted causes of segmentation fault.
It is reported that pgpool and its child process segfault in certain
cases when failover involved.
Hhealth check has an issue with connection "slot" memory. It is
managed by HealthCheckMemoryContext. slot is the pointer to the
memory. When elog(ERROR) is raised, pgpool long jumps and resets the
memory context. Thus, slot remains as a pointer to freed memory. To
fix this, always set NULL to slot right after the
HealthCheckMemoryContext call.
Similar issue is found with streaming replication check too and is
also fixed in this commit.
Problem reported and analyzed: Emond Papegaaij
Backpatch-through: v4.3-v4.1
Discussion:
[pgpool-general: 9070] Re: Segmentation after switchover
Branch
------
V4_3_STABLE
Details
-------
https://git.postgresql.org/gitweb?p=pgpool2.git;a=commitdiff;h=4bd1450d9c97cd7ca0154f873573b8fe1b4edd16
Modified Files
--------------
src/main/health_check.c | 8 +++++++-
src/streaming_replication/pool_worker_child.c | 8 +++++++-
2 files changed, 14 insertions(+), 2 deletions(-)
More information about the pgpool-committers
mailing list