pgsql: Fix minor oversights in nodeAgg.c.

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: pgsql-committers(at)postgresql(dot)org
Subject: pgsql: Fix minor oversights in nodeAgg.c.
Date: 2016-12-21 00:22:08
Message-ID: E1cJUfY-0007YS-6l@gemulon.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Fix minor oversights in nodeAgg.c.

aggstate->evalproj is always set up by ExecInitAgg, so there's no
need to test. Doing so led Coverity to think that we might be
intending "slot" to be possibly NULL here, and it quite properly
complained that the rest of combine_aggregates() wasn't prepared
for that.

Also fix a couple of obvious thinkos in Asserts checking that
"inputoff" isn't past the end of the slot.

Errors introduced in commit 8ed3f11bb, so no need for back-patch.

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/c080b223a7a3991524a5287416a0ad756c15a098

Modified Files
--------------
src/backend/executor/nodeAgg.c | 11 +++++------
1 file changed, 5 insertions(+), 6 deletions(-)

Browse pgsql-committers by date

  From Date Subject
Next Message Pavel Stehule 2016-12-21 07:14:12 Re: pgsql: Simplify LWLock tranche machinery by removing array_base/array_s
Previous Message Tom Lane 2016-12-20 23:54:18 pgsql: Fix minor error message style violation.