Re: [HACKERS] Memory problem?
От | Tom Lane |
---|---|
Тема | Re: [HACKERS] Memory problem? |
Дата | |
Msg-id | 22580.929454935@sss.pgh.pa.us обсуждение исходный текст |
Ответ на | Memory problem? ("Patrick Welche" <prlw1@newn.cam.ac.uk>) |
Ответы |
Re: [HACKERS] Memory problem?
|
Список | pgsql-hackers |
"Patrick Welche" <prlw1@newn.cam.ac.uk> writes: > I am having trouble with PQclear causing a segmentation fault, and I don't > really know where to look. Not at PQclear(); almost surely, the bug lies elsewhere. The most likely bets are (a) that PQclear is being called twice for the same PGresult (although this looks unlikely with the current libpq++, since it doesn't give the calling app direct access to the PGresult), or (b) that some random other bit of code is clobbering memory that doesn't belong to it. When you make a mistake like writing a little bit past the end of a malloc'd piece of memory, the usual symptom is coredumps in later malloc or free operations, because what you've clobbered is malloc's memory management data structures. Unfortunately that means the bug might be almost anywhere else in your app :-(. Good luck... regards, tom lane
В списке pgsql-hackers по дате отправления: