Re: Patch to allow pg_filedump to support reading of pg_filenode.map

Поиск
Список
Период
Сортировка
От Richard Yen
Тема Re: Patch to allow pg_filedump to support reading of pg_filenode.map
Дата
Msg-id CAKH4vDhz+HCo1e+6nNyT+XZTQBY9OscqfwY=NbKfK_jxxQnKDw@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Patch to allow pg_filedump to support reading of pg_filenode.map  (Justin Pryzby <pryzby@telsasoft.com>)
Список pgsql-hackers


On Thu, Apr 29, 2021 at 12:05 PM Justin Pryzby <pryzby@telsasoft.com> wrote:
I think you should be able to avoid crashing if passed a non-relmapper file.
Make sure not to loop over more mappings than exist in the relmapper file of
the given size.

I guess you should warn if the number of mappings is too large for the file's
size.  And then "cap" the number of mappings to the maximum possible number.

Ah, thanks for the tip.  That's right -- I can't assume the user's input is a valid file.  Updated patch here.

--Richard


 

--
Justin
Вложения

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

Предыдущее
От: Justin Pryzby
Дата:
Сообщение: Re: Patch to allow pg_filedump to support reading of pg_filenode.map
Следующее
От: Joe Conway
Дата:
Сообщение: Re: function for testing that causes the backend to terminate