Re: bug in SignalSomeChildren

Поиск
Список
Период
Сортировка
От Robert Haas
Тема Re: bug in SignalSomeChildren
Дата
Msg-id AANLkTikU-SfvkuW3XbD=zwmvGQ86jk7ezXpTOtuPfEMi@mail.gmail.com
обсуждение исходный текст
Ответ на Re: bug in SignalSomeChildren  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: bug in SignalSomeChildren  (Tom Lane <tgl@sss.pgh.pa.us>)
Re: bug in SignalSomeChildren  (Martijn van Oosterhout <kleptog@svana.org>)
Список pgsql-hackers
On Mon, Dec 20, 2010 at 2:23 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
> Robert Haas <robertmhaas@gmail.com> writes:
>> Another option that might be workable (but I have reservations, and
>> haven't tested it either) is to check whether the return value of
>> getppid() is equal to 1.  If it's neither 1 nor PostmasterPid then try
>> kill().
>
> I like that better actually ... one less thing for developers to get wrong.

The attached patch appears to work correctly on MacOS X.  I did check,
BTW: getppid() in the attached process returns gdb's pid.  Poor!

For my own purposes, I would be just as happy to apply this only to
master.  But I wonder if anyone wants to argue for back-patching, to
help debug existing installations?

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

Вложения

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

Предыдущее
От: Kenneth Marshall
Дата:
Сообщение: Re: Extensions, patch v20 (bitrot fixes)
Следующее
От: "David E. Wheeler"
Дата:
Сообщение: Re: Extensions, patch v20 (bitrot fixes)