Re: Trouble debugging contrib/fulltextindex

Поиск
Список
Период
Сортировка
От Peter Eisentraut
Тема Re: Trouble debugging contrib/fulltextindex
Дата
Msg-id Pine.LNX.4.44.0208212107270.1376-100000@localhost.localdomain
обсуждение исходный текст
Ответ на Trouble debugging contrib/fulltextindex  ("Christopher Kings-Lynne" <chriskl@familyhealth.com.au>)
Список pgsql-hackers
Christopher Kings-Lynne writes:

> 1. How do you compile contribs with full debugging symbols.  I always get
> heuristic-fencepost-blah probs with gdb even though I've configured postgres
> with all the debugging stuff.

First, compile without optimization (-O0).  Second, using LOAD to load the
shared object before the function call may be of advantage.  I would allow
you to set breakpoints in the loaded object, for example.  Just waiting
for the code to crash and hoping to get a good backtrace isn't always a
successful strategy.

> 2. Should contribs exclusively use palloc/pfree?

Yes (unless there are some wildly unusual memory allocation requirements).

-- 
Peter Eisentraut   peter_e@gmx.net



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Peter Eisentraut
Дата:
Сообщение: Re: bison news
Следующее
От: Peter Eisentraut
Дата:
Сообщение: Re: Build failure in current CVS