mirror of
https://github.com/postgres/postgres.git
synced 2026-04-23 07:07:22 -04:00
Avoid memory leakage during VACUUM FULL when an index expression or
index predicate uses temporary memory for evaluation. Per example from Jean-Gerard Pailloncy.
This commit is contained in:
parent
b6c56b73e7
commit
715a73427e
1 changed files with 3 additions and 1 deletions
|
|
@ -13,7 +13,7 @@
|
|||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/backend/commands/vacuum.c,v 1.263 2003/10/02 23:19:44 tgl Exp $
|
||||
* $Header: /cvsroot/pgsql/src/backend/commands/vacuum.c,v 1.263.2.1 2004/12/23 22:42:32 tgl Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
|
|
@ -2041,6 +2041,7 @@ repair_frag(VRelStats *vacrelstats, Relation onerel,
|
|||
ExecStoreTuple(&newtup, slot, InvalidBuffer, false);
|
||||
ExecInsertIndexTuples(slot, &(newtup.t_self),
|
||||
estate, true);
|
||||
ResetPerTupleExprContext(estate);
|
||||
}
|
||||
|
||||
WriteBuffer(cur_buffer);
|
||||
|
|
@ -2174,6 +2175,7 @@ repair_frag(VRelStats *vacrelstats, Relation onerel,
|
|||
{
|
||||
ExecStoreTuple(&newtup, slot, InvalidBuffer, false);
|
||||
ExecInsertIndexTuples(slot, &(newtup.t_self), estate, true);
|
||||
ResetPerTupleExprContext(estate);
|
||||
}
|
||||
} /* walk along page */
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue