Re: Using defines for protocol characters

Поиск
Список
Период
Сортировка
От Michael Paquier
Тема Re: Using defines for protocol characters
Дата
Msg-id ZN1qe0dYIIKmzOPo@paquier.xyz
обсуждение исходный текст
Ответ на Re: Using defines for protocol characters  (Nathan Bossart <nathandbossart@gmail.com>)
Ответы Re: Using defines for protocol characters  (Nathan Bossart <nathandbossart@gmail.com>)
Список pgsql-hackers
On Wed, Aug 16, 2023 at 12:29:56PM -0700, Nathan Bossart wrote:
> I moved the definitions out to a separate file in v6.

Looks sensible seen from here.

This patch is missing the installation of protocol.h in
src/tools/msvc/Install.pm for MSVC.  For pqcomm.h, we are doing that:
lcopy('src/include/libpq/pqcomm.h', $target . '/include/internal/libpq/')
    || croak 'Could not copy pqcomm.h';

So adding two similar lines for protocol.h should be enough (I assume,
did not test).

In fe-exec.c, we still have a few things for the type of objects to
work on:
- 'S' for statement.
- 'P' for portal.
Should these be added to protocol.h?  They are part of the extended
protocol.

The comment at the top of PQsendTypedCommand() mentions 'C' and 'D',
but perhaps these should be updated to the object names instead?

pqFunctionCall3(), for PQfn(), has a few more hardcoded characters for
its status codes.  I'm OK to do things incrementally so it's fine by
me to not add them now, just noticing on the way what could be added
to this new header.
--
Michael

Вложения

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

Предыдущее
От: Peter Geoghegan
Дата:
Сообщение: Re: Rename ExtendedBufferWhat in 16?
Следующее
От: Michael Paquier
Дата:
Сообщение: Re: Return value of pg_promote()