pgsql: Remove configure probes for sockaddr_storage members.

Поиск
Список
Период
Сортировка
От Thomas Munro
Тема pgsql: Remove configure probes for sockaddr_storage members.
Дата
Msg-id E1oQ0Nm-000efb-Gl@gemulon.postgresql.org
обсуждение исходный текст
Список pgsql-committers
Remove configure probes for sockaddr_storage members.

Remove four probes for members of sockaddr_storage.  Keep only the probe
for sockaddr's sa_len, which is enough for our two remaining places that
know about _len fields:

1.  ifaddr.c needs to know if sockaddr has sa_len to understand the
result of ioctl(SIOCGIFCONF).  Only AIX is still using the relevant code
today, but it seems like a good idea to keep it compilable on Linux.

2.  ip.c was testing for presence of ss_len to decide whether to fill in
sun_len in our getaddrinfo_unix() function.  It's just as good to test
for sa_len.  If you have one, you have them all.

(The code in #2 isn't actually needed at all on several OSes I checked
since modern versions ignore sa_len on input to system calls.  Proving
that's the case for all relevant OSes is left for another day, but
wouldn't get rid of that last probe anyway if we still want it for #1.)

Discussion: https://postgr.es/m/CA%2BhUKGJJjF2AqdU_Aug5n2MAc1gr%3DGykNjVBZq%2Bd6Jrcp3Dyvg%40mail.gmail.com

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/64ef572c068fde7cbba7f82cd50f51c0131ffe3b

Modified Files
--------------
config/c-library.m4        | 18 ++++++-----------
configure                  | 48 ----------------------------------------------
configure.ac               |  2 +-
src/common/ip.c            |  2 +-
src/include/libpq/pqcomm.h | 13 -------------
src/include/pg_config.h.in | 12 ------------
src/tools/msvc/Solution.pm |  4 ----
7 files changed, 8 insertions(+), 91 deletions(-)


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

Предыдущее
От: Amit Kapila
Дата:
Сообщение: pgsql: Use logical operator && instead of & in vacuumparallel.c.
Следующее
От: Peter Eisentraut
Дата:
Сообщение: pgsql: pg_upgrade: Fix thinko in database info acquisition routine