Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 5392e73

Browse files
committed
Added missing SPI_finish() calls to get_tuple_of_interest(). Fixes bug
reported by Andrea Grassi.
1 parent 185430a commit 5392e73

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

contrib/dblink/dblink.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1766,6 +1766,7 @@ get_tuple_of_interest(Oid relid, int16 *pkattnums, int16 pknumatts, char **src_p
17661766
SPITupleTable *tuptable = SPI_tuptable;
17671767

17681768
tuple = SPI_copytuple(tuptable->vals[0]);
1769+
SPI_finish();
17691770

17701771
return tuple;
17711772
}
@@ -1774,6 +1775,8 @@ get_tuple_of_interest(Oid relid, int16 *pkattnums, int16 pknumatts, char **src_p
17741775
/*
17751776
* no qualifying tuples
17761777
*/
1778+
SPI_finish();
1779+
17771780
return NULL;
17781781
}
17791782

0 commit comments

Comments
 (0)