aboutsummaryrefslogtreecommitdiff
path: root/src/backend/utils/adt/json.c
diff options
context:
space:
mode:
authorAlvaro Herrera <alvherre@alvh.no-ip.org>2013-12-20 12:37:30 -0300
committerAlvaro Herrera <alvherre@alvh.no-ip.org>2013-12-20 12:37:30 -0300
commitfd995b3f4fe52ecd45d06f8cb8b9d217298df917 (patch)
tree2266d8825efcdffa1b9875967920b3886a3603ff /src/backend/utils/adt/json.c
parent85d3b3c3ac16ea7d8f7b513d8ac7bc2f88bb988f (diff)
downloadpostgresql-fd995b3f4fe52ecd45d06f8cb8b9d217298df917.tar.gz
postgresql-fd995b3f4fe52ecd45d06f8cb8b9d217298df917.zip
Avoid useless palloc during transaction commit
We can allocate the initial relations-to-drop array when first needed, instead of at function entry; this avoids allocating it when the function is not going to do anything, which is most of the time. Backpatch to 9.3, where this behavior was introduced by commit 279628a0a7cf5. There's more that could be done here, such as possible reworking of the code to avoid having to palloc anything, but that doesn't sound as backpatchable as this relatively minor change. Per complaint from Noah Misch in 20131031145234.GA621493@tornado.leadboat.com
Diffstat (limited to 'src/backend/utils/adt/json.c')
0 files changed, 0 insertions, 0 deletions