From aebbb7a15a3e5f5ec8bea69342c3b0c6ea13e21c Mon Sep 17 00:00:00 2001 From: =?utf8?q?Ra=C3=BAl=20Mar=C3=ADn=20Rodr=C3=ADguez?= Date: Mon, 29 Jul 2019 15:32:29 +0000 Subject: [PATCH] Fix undefined behaviour in _postgis_gserialized_stats References #4466 git-svn-id: http://svn.osgeo.org/postgis/branches/2.3@17632 b70326c6-7e19-0410-871a-916f4a2858ee --- NEWS | 1 + postgis/gserialized_estimate.c | 4 ---- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/NEWS b/NEWS index c485a04b4..6ede78aa5 100644 --- a/NEWS +++ b/NEWS @@ -8,6 +8,7 @@ PostGIS 2.3.10 - #4388, AddRasterConstraints: Ignore NULLs when generating constraints (Raúl Marín) - #4327, Avoid pfree'ing the result of getenv (Raúl Marín) - #4406, Throw on invalid characters when decoding geohash (Raúl Marín) + - #4466, Fix undefined behaviour in _postgis_gserialized_stats (Raúl Marín) PostGIS 2.3.9 diff --git a/postgis/gserialized_estimate.c b/postgis/gserialized_estimate.c index 9168c9ff0..741ed4a15 100644 --- a/postgis/gserialized_estimate.c +++ b/postgis/gserialized_estimate.c @@ -2002,10 +2002,6 @@ Datum _postgis_gserialized_stats(PG_FUNCTION_ARGS) if ( ! PG_ARGISNULL(2) ) mode = text_p_get_mode(PG_GETARG_TEXT_P(2)); - /* Check if we've been asked to only use stats from parent */ - if ( ! PG_ARGISNULL(3) ) - only_parent = PG_GETARG_BOOL(3); - /* Retrieve the stats object */ nd_stats = pg_get_nd_stats_by_name(table_oid, att_text, mode, only_parent); if ( ! nd_stats ) -- 2.49.0