use inet_pton() instead of inet_addr() for ipv4/6

From: Pavel Raiskup <praiskup(at)redhat(dot)com>
To: "pgsql-odbc(at)postgresql(dot)org" <pgsql-odbc(at)postgresql(dot)org>
Subject: use inet_pton() instead of inet_addr() for ipv4/6
Date: 2013-12-06 10:58:10
Message-ID: 3932297.uqAmftHYU6@nb.usersys.redhat.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-odbc

Hi, our regular package checking discovered that in postgresql-odbc is
using inet_addr() call (which is not ipv6 compliant). I tried to look at
it and it was used just for parsing of ipv4 addresses. It is not a big
deal (the worst thing what can happen is that ipv6 addresses will cost a
little bit more time to be resolved).

Better solution would be imo to use inet_pton() call for both ipv4 and
ipv6 address families. Patch is attached, any comment is welcome!

Pavel

Attachment Content-Type Size
0001-socket-speedup-also-ipv6-connection.patch text/x-patch 1.5 KB

Responses

Browse pgsql-odbc by date

  From Date Subject
Next Message Pavel Raiskup 2013-12-06 17:08:37 [PATCH] Silence GCC warnings, fix build
Previous Message Daniel Homerick 2013-12-06 00:32:40 Checksum error via Stackbuilder 3.1.1