pg.ddx.io pgsql-committers@postgresql.org mailing list archivehelp / color / mirror / Atom feed
pgsql: Guard against possible memory allocation botch in batchmemtuples 2+ messages / 1 participants [nested] [flat]
* pgsql: Guard against possible memory allocation botch in batchmemtuples @ 2016-09-06 19:50 Tom Lane <tgl@sss.pgh.pa.us> 0 siblings, 0 replies; 2+ messages in thread From: Tom Lane @ 2016-09-06 19:50 UTC (permalink / raw) To: pgsql-committers Guard against possible memory allocation botch in batchmemtuples(). Negative availMemLessRefund would be problematic. It's not entirely clear whether the case can be hit in the code as it stands, but this seems like good future-proofing in any case. While we're at it, insist that the value be not merely positive but not tiny, so as to avoid doing a lot of repalloc work for little gain. Peter Geoghegan Discussion: <CAM3SWZRVkuUB68DbAkgw=532gW0f+fofKueAMsY7hVYi68MuYQ@mail.gmail.com> Branch ------ master Details ------- http://git.postgresql.org/pg/commitdiff/f032722f86a709277d44a317a3bc8acd74861a72 Modified Files -------------- src/backend/utils/sort/tuplesort.c | 23 +++++++++++++++++++++-- 1 file changed, 21 insertions(+), 2 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers ^ permalink raw reply [nested|flat] 2+ messages in thread
* pgsql: Guard against possible memory allocation botch in batchmemtuples @ 2016-09-06 19:50 Tom Lane <tgl@sss.pgh.pa.us> 0 siblings, 0 replies; 2+ messages in thread From: Tom Lane @ 2016-09-06 19:50 UTC (permalink / raw) To: pgsql-committers Guard against possible memory allocation botch in batchmemtuples(). Negative availMemLessRefund would be problematic. It's not entirely clear whether the case can be hit in the code as it stands, but this seems like good future-proofing in any case. While we're at it, insist that the value be not merely positive but not tiny, so as to avoid doing a lot of repalloc work for little gain. Peter Geoghegan Discussion: <CAM3SWZRVkuUB68DbAkgw=532gW0f+fofKueAMsY7hVYi68MuYQ@mail.gmail.com> Branch ------ REL9_6_STABLE Details ------- http://git.postgresql.org/pg/commitdiff/96ba40c0f15aa1e950b35536387fde30ebbc4547 Modified Files -------------- src/backend/utils/sort/tuplesort.c | 23 +++++++++++++++++++++-- 1 file changed, 21 insertions(+), 2 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers ^ permalink raw reply [nested|flat] 2+ messages in thread
end of thread, other threads:[~2016-09-06 19:50 UTC | newest] Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed) -- links below jump to the message on this page -- 2016-09-06 19:50 pgsql: Guard against possible memory allocation botch in batchmemtuples Tom Lane <tgl@sss.pgh.pa.us> 2016-09-06 19:50 pgsql: Guard against possible memory allocation botch in batchmemtuples Tom Lane <tgl@sss.pgh.pa.us>
This inbox is served by DDX for PostgreSQL; see mirroring instructions for how to clone and mirror all data and code used for this inbox