diff options
author | Michael Stapelberg <michael@stapelberg.de> | 2009-08-23 20:20:52 +0200 |
---|---|---|
committer | Michael Stapelberg <michael@stapelberg.de> | 2009-09-26 13:24:36 +0200 |
commit | 89ad3dbaa258f3c15957d5f69558d070e3c5d9bc (patch) | |
tree | 7f94e31aa668fdbd235b42d3d48b964623f6594f | |
parent | 48e033598bf8d97e3663b2b854ed4f6aa03585de (diff) |
Don’t display an error message if getaddrinfo() fails for getting the IPv6 addr (Thanks Atsutane)
-rw-r--r-- | src/get_ipv6_addr.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/get_ipv6_addr.c b/src/get_ipv6_addr.c index 0f22e29..341b5ba 100644 --- a/src/get_ipv6_addr.c +++ b/src/get_ipv6_addr.c @@ -25,7 +25,9 @@ const char *get_ipv6_addr() { * replace this with any other host which has an AAAA record, but the * K root server is a pretty safe bet. */ if (getaddrinfo("k.root-servers.net", "domain", &hints, &result) != 0) { - perror("getaddrinfo()"); + /* We don’t display the error here because most + * likely, there just is no connectivity. + * Thus, don’t spam the user’s console. */ return "no IPv6"; } |