Re: pgsql: Add support for TCP keepalives on Windows, both for backend and

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: pgsql: Add support for TCP keepalives on Windows, both for backend and
Дата
Msg-id 26004.1278603554@sss.pgh.pa.us
обсуждение исходный текст
Ответ на pgsql: Add support for TCP keepalives on Windows, both for backend and  (mha@postgresql.org (Magnus Hagander))
Ответы Re: pgsql: Add support for TCP keepalives on Windows, both for backend and  (Magnus Hagander <magnus@hagander.net>)
Re: [HACKERS] pgsql: Add support for TCP keepalives on Windows, both for backend and  (Andrew Dunstan <andrew@dunslane.net>)
Список pgsql-committers
Magnus Hagander <magnus@hagander.net> writes:
> Seems pretty simple - mingw doesn't have support for this. We have two
> ways to deal with that I think:
> 1) Disable it on mingw.
> 2) Include it in our custom headers.

> For #2, what we need to include is the define of SIO_KEEPALIVE_VALS as
> well as the definition of struct tcp_keepalive.

> We've done #2 before at least once, which worked well until mingw
> suddenly caught up and added it a while later. It's not like this is a
> new definition in windows, but we need to be ready for them to
> eventually do that.

Yeah.  I'm satisfied with doing #1 and waiting for them to fix it.

> I guess there is:
> 3) write an autoconf test and provide them only when mingw doesn't have it.
> if we're going with #3, I'll respectfully have to ask somebod yelse to
> write the autoconf test, that's beyond me I think :-)

An easy approximation would be to make the code #ifdef SIO_KEEPALIVE_VALS.
That would fail if the mingw guys decide to provide the #define without
adding the struct at the same time, but that seems moderately unlikely.

            regards, tom lane

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

Предыдущее
От: tgl@postgresql.org (Tom Lane)
Дата:
Сообщение: pgsql: Fix variant float8 expected files to have exactly the expected
Следующее
От: Magnus Hagander
Дата:
Сообщение: Re: pgsql: Add support for TCP keepalives on Windows, both for backend and