mirror of https://github.com/postgres/postgres
Fixed growing of backend due to not pfree()'d data on COPY FROM
Fixed growing of backend if BEFORE DELETE trigger returns heap tuple different from trigtuple. Jan
This commit is contained in:
parent
072be47202
commit
7fc75517df
|
@ -6,7 +6,7 @@
|
|||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/backend/commands/copy.c,v 1.68 1999/01/23 22:27:26 tgl Exp $
|
||||
* $Header: /cvsroot/pgsql/src/backend/commands/copy.c,v 1.69 1999/02/01 20:25:54 wieck Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
|
@ -651,7 +651,6 @@ CopyFrom(Relation rel, bool binary, bool oids, FILE *fp, char *delim)
|
|||
lineno = 0;
|
||||
while (!done)
|
||||
{
|
||||
values = (Datum *) palloc(sizeof(Datum) * attr_count);
|
||||
if (!binary)
|
||||
{
|
||||
#ifdef COPY_PATCH
|
||||
|
|
|
@ -684,6 +684,8 @@ ExecBRDeleteTriggers(EState *estate, ItemPointer tupleid)
|
|||
newtuple = ExecCallTriggerFunc(trigger[i]);
|
||||
if (newtuple == NULL)
|
||||
break;
|
||||
if (newtuple != trigtuple)
|
||||
pfree(newtuple);
|
||||
}
|
||||
CurrentTriggerData = NULL;
|
||||
pfree(SaveTriggerData);
|
||||
|
|
Loading…
Reference in New Issue