postgresql/src/backend
Tom Lane f032722f86 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>
2016-09-06 15:50:31 -04:00
..
access Fix corrupt GIN_SEGMENT_ADDITEMS WAL records on big-endian hardware. 2016-09-03 13:28:53 -04:00
bootstrap Fix a bunch of places that called malloc and friends with no NULL check. 2016-08-30 18:22:43 -04:00
catalog Try to fix portability issue in enum renumbering (again). 2016-08-31 13:58:01 -04:00
commands Fix VACUUM_TRUNCATE_LOCK_WAIT_INTERVAL 2016-09-06 15:35:47 +01:00
executor Add macros to make AllocSetContextCreate() calls simpler and safer. 2016-08-27 17:50:38 -04:00
foreign Remove GetUserMappingId() and GetUserMappingById(). 2016-07-22 11:32:23 -04:00
lib Clarify the new Red-Black post-order traversal code a bit. 2016-09-04 15:02:06 +03:00
libpq Move code shared between libpq and backend from backend/libpq/ to common/. 2016-09-02 13:49:59 +03:00
main Repair a bit of pgindent damage. 2016-06-09 18:09:17 -04:00
nodes Fix improper repetition of previous results from a hashed aggregate. 2016-08-24 14:38:12 -04:00
optimizer Add macros to make AllocSetContextCreate() calls simpler and safer. 2016-08-27 17:50:38 -04:00
parser Improve parsetree representation of special functions such as CURRENT_DATE. 2016-08-16 20:33:01 -04:00
po Translation updates 2016-08-08 11:08:00 -04:00
port Fix a bunch of places that called malloc and friends with no NULL check. 2016-08-30 18:22:43 -04:00
postmaster Move code shared between libpq and backend from backend/libpq/ to common/. 2016-09-02 13:49:59 +03:00
regex Make locale-dependent regex character classes work for large char codes. 2016-09-05 17:06:29 -04:00
replication Dirty replication slots when using sql interface 2016-09-05 09:44:38 +01:00
rewrite pgindent run for 9.6 2016-06-09 18:02:36 -04:00
snowball Update copyright for 2016 2016-01-02 13:33:40 -05:00
storage Add debug check function LWLockHeldByMeInMode() 2016-09-05 10:38:08 +01:00
tcop Relax transactional restrictions on ALTER TYPE ... ADD VALUE. 2016-09-05 12:59:55 -04:00
tsearch Add macros to make AllocSetContextCreate() calls simpler and safer. 2016-08-27 17:50:38 -04:00
utils Guard against possible memory allocation botch in batchmemtuples(). 2016-09-06 15:50:31 -04:00
.gitignore Add .gitignore entries for AIX-specific intermediate build artifacts. 2015-07-08 20:44:22 -04:00
Makefile Provide and use a makefile target to build all generated headers. 2016-07-01 15:09:02 -04:00
common.mk Remove maintainer-check target, fold into normal build 2013-10-10 20:11:56 -04:00
nls.mk Remove trailing slashes from directories in find command 2015-09-18 22:06:54 -04:00