Re: pg_dump 9.1.1 hanging (collectSecLabels gets 0 labels)

Поиск
Список
Период
Сортировка
От Steve Singer
Тема Re: pg_dump 9.1.1 hanging (collectSecLabels gets 0 labels)
Дата
Msg-id 4EBC1436.20105@ca.afilias.info
обсуждение исходный текст
Ответ на Re: pg_dump 9.1.1 hanging (collectSecLabels gets 0 labels)  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: pg_dump 9.1.1 hanging (collectSecLabels gets 0 labels)  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
On 11-11-09 06:35 PM, Tom Lane wrote:
> Steve Singer<ssinger@ca.afilias.info>  writes:
>> I've tracked the issue down to collectSecLabels in pg_dump.c
>
>> SELECT label, provider, classoid, objoid, objsbid FROM
>> pg_catalog.pg_seclabel;
>
>> returns 0 rows.
>
>> The code in collectSecLabels() is not prepared to deal with a zero row
>> result and tries to malloc 0 bytes.
>
> pg_seclabel is almost always empty, so I'm not convinced that you've
> identified your problem correctly.
>
>             regards, tom lane
>

The attached patch seems to fix the issue.

The man page for malloc on AIX is pretty clear on what happens when you
try to malloc 0 bytes.  It returns NULL.

Вложения

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

Предыдущее
От: Bruce Momjian
Дата:
Сообщение: Re: warning in pg_upgrade
Следующее
От: Scott Mead
Дата:
Сообщение: Re: IDLE in transaction introspection