]> granicus.if.org Git - postgresql/commit
Don't cache per-group context across the whole query in orderedsetaggs.c.
authorTom Lane <tgl@sss.pgh.pa.us>
Thu, 3 Jul 2014 22:47:09 +0000 (18:47 -0400)
committerTom Lane <tgl@sss.pgh.pa.us>
Thu, 3 Jul 2014 22:47:22 +0000 (18:47 -0400)
commite44964c709b4a5f18d3f9a8fe6d5c259091315c1
tree472b61f117ddf3ae1ad4eecf7acb93c17bfde66f
parentf688cf548b3e37991009b7a3607171242c796e62
Don't cache per-group context across the whole query in orderedsetaggs.c.

Although nodeAgg.c currently uses the same per-group memory context for
all groups of a query, that might change in future.  Avoid assuming it.
This costs us an extra AggCheckCallContext() call per group, but that's
pretty cheap and is probably good from a safety standpoint anyway.

Back-patch to 9.4 in case any third-party code copies this logic.

Andrew Gierth
src/backend/utils/adt/orderedsetaggs.c