Commit 92ab5dc2 authored by Vadim B. Mikheev's avatar Vadim B. Mikheev

Little memmory leak in RelationFlushRelation() in freeing

relation->rd_att (relation' TupleDesc).
parent b0dfe8e3
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/cache/relcache.c,v 1.6 1996/11/27 08:16:01 bryanh Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/cache/relcache.c,v 1.7 1997/05/20 11:41:38 vadim Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
...@@ -1220,11 +1220,11 @@ RelationFlushRelation(Relation *relationPtr, ...@@ -1220,11 +1220,11 @@ RelationFlushRelation(Relation *relationPtr,
FileInvalidate(RelationGetSystemPort(relation)); FileInvalidate(RelationGetSystemPort(relation));
i = relation->rd_rel->relnatts - 1; p = relation->rd_att->attrs;
p = &relation->rd_att->attrs[i]; for (i = 0; i < relation->rd_rel->relnatts; i++, p++)
while ((i -= 1) >= 0) { pfree (*p);
pfree(*p--); pfree (relation->rd_att->attrs);
} pfree (relation->rd_att);
#if 0 #if 0
if (relation->rd_rules) { if (relation->rd_rules) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment