Re: Add LZ4 compression in pg_dump

Поиск
Список
Период
Сортировка
От Michael Paquier
Тема Re: Add LZ4 compression in pg_dump
Дата
Msg-id ZDdOstf12KHSarmS@paquier.xyz
обсуждение исходный текст
Ответ на Re: Add LZ4 compression in pg_dump  (Justin Pryzby <pryzby@telsasoft.com>)
Ответы Re: Add LZ4 compression in pg_dump  (Justin Pryzby <pryzby@telsasoft.com>)
Список pgsql-hackers
On Wed, Apr 12, 2023 at 05:52:40PM -0500, Justin Pryzby wrote:
> I don't think you need to call parse_compress_specification(NONE).
> As you wrote it, if zlib is unavailable, there's no parse(NONE) call,
> even for directory and custom formats.  And there's no parse(NONE) call
> for plan format when zlib is available.

Yeah, that's not necessary, but I was wondering if it made the code a
bit cleaner, or else the non-zlib path would rely on the default
compression method string.

> The old way had preprocessor #if around both the "if" and "else" - is
> that what you meant?
>
> If you don't insist on calling parse(NONE), the only change is to remove
> the empty #else, which was my original patch.

Removing the empty else has as problem to create an empty if block,
which could be itself a cause of warnings?

> If I were to rewrite the comment, it'd say:
>
> +        * When gzip is available, custom and directory formats are compressed by
> +        * default

Okay.
--
Michael

Вложения

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

Предыдущее
От: Melanie Plageman
Дата:
Сообщение: Re: Wrong results from Parallel Hash Full Join
Следующее
От: Thomas Munro
Дата:
Сообщение: Re: Clean up hba.c of code freeing regexps