[pgpool-committers: 6429] pgpool: Fix replication delay worker segfault when application_name is

Tatsuo Ishii ishii at sraoss.co.jp
Thu Dec 12 18:20:46 JST 2019


Fix replication delay worker segfault when application_name is an empty string.

The process calls do_query() to obtain the query result against
pg_stat_replication_view.  If user sets application_name to an empty
string, the result data row packet length will be 0. However
do_query() did not consider the length == 0 case, which resulted in
giving NULL pointer to strcmp() which is called from the worker
process. That means the bug is not specific to this case (a new
feature added in Pgpool-II 4.1) but it potentially affects many other
places where do_query() gets called, although it had not been reported
in the field. So this fix should be applied to all supported branches.

Per bug 565.

Branch
------
V3_5_STABLE

Details
-------
https://git.postgresql.org/gitweb?p=pgpool2.git;a=commitdiff;h=88f11799cb29a91bcd1d9fcddb3d49c67f854b38

Modified Files
--------------
src/protocol/pool_process_query.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)



More information about the pgpool-committers mailing list