[pgpool-committers: 2117] pgpool: Fix for the segmentation fault, which was unearthed while testi
m.usama at gmail.com
Thu Aug 7 20:47:44 JST 2014
Fix for the segmentation fault, which was unearthed while testing. The crash only
exists in master branch, and was caused by import of memory manager.
The reason for the crash was check_copy_from_stdin() function was making the persistent copies
of copy_schema, copy_nulls and copy_table in wrong memory context, whose lifecycle
is shorter than the lifecycle of global variables (copy_schema, copy_nulls and copy_table).
This checkin fix the fault by replacing pstrdup() with
MemoryContextStrdup() and using TopMemoryContext.
src/protocol/pool_process_query.c | 13 +++++++------
1 file changed, 7 insertions(+), 6 deletions(-)
More information about the pgpool-committers