pgsql: Remove dead ifaddr.c fallback code.

From: Thomas Munro <tmunro(at)postgresql(dot)org>
To: pgsql-committers(at)lists(dot)postgresql(dot)org
Subject: pgsql: Remove dead ifaddr.c fallback code.
Date: 2022-08-18 04:34:02
Message-ID: E1oOXEH-0003fb-6L@gemulon.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Remove dead ifaddr.c fallback code.

We carried a special implementation of pg_foreach_ifaddr() using
Solaris's ioctl(SIOCGLIFCONF), but Solaris 11 and illumos adopted
getifaddrs() more than a decade ago, and we prefer to use that. Solaris
10 is EOL'd. Remove the dead code.

Adjust comment about which OSes have getifaddrs(), which also
incorrectly listed AIX. AIX is in fact the only Unix in the build farm
that *doesn't* have it today, so the implementation based on
ioctl(SIOCGIFCONF) (note, no 'L') is still live. All the others have
had it for at least one but mostly two decades.

The last-stop fallback at the bottom of the file is dead code in
practice, but it's hard to justify removing it because the better
options are all non-standard.

Discussion: https://postgr.es/m/CA+hUKGKErNfhmvb_H0UprEmp4LPzGN06yR2_0tYikjzB-2ECMw@mail.gmail.com

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/a717cddcac518162cc17bae3c68a492db9ab2e75

Modified Files
--------------
src/backend/libpq/ifaddr.c | 112 +--------------------------------------------
1 file changed, 2 insertions(+), 110 deletions(-)

Browse pgsql-committers by date

  From Date Subject
Next Message Peter Eisentraut 2022-08-18 09:49:15 Re: pgsql: Refer to replication origin roident as "ID" in user facing messa
Previous Message John Naylor 2022-08-18 02:50:15 pgsql: Update comment in gramparse.h