mirror of https://github.com/postgres/postgres
Allocate PLyResultObject.tupdesc in TopMemoryContext, because its lifetime is the lifetime of the Python object and it shouldn't be freed by some other memory context, such as one controlled by SPI. We trust that the Python object will clean up its own memory. Before, this would crash the included regression test case by trying to use memory that was already freed. reported by Asif Naeem, analysis by Tom Lanepull/3/head
parent
e9605a039b
commit
52aa334fcd
Loading…
Reference in new issue