Release any detoasted copies of arrays that are made temporarily in
authorTom Lane <tgl@sss.pgh.pa.us>
Fri, 25 Jan 2008 04:46:07 +0000 (04:46 +0000)
committerTom Lane <tgl@sss.pgh.pa.us>
Fri, 25 Jan 2008 04:46:07 +0000 (04:46 +0000)
commit93284b7791beb7a1333be67760c50350b4d6fa39
treee85d3713df02aaa1ec98af3616f8fce88e49d438
parentd99fcae4b2be8734f1fd013376f6cb93abd1ad98
Release any detoasted copies of arrays that are made temporarily in
ri_FetchConstraintInfo, to avoid a query-duration memory leak when that
routine is called by RI_FKey_keyequal_upd_fk (which isn't executed in a
short-lived context).  This problem was latent when the routine was added
in February, but it didn't become serious until the varvarlena patch made
it quite likely that the fields being examined would be "toasted" (ie, have
short headers).  Per report from Stephen Denne.
src/backend/utils/adt/ri_triggers.c