diff options
author | Ludovic Courtès <ludo@gnu.org> | 2015-11-12 23:15:18 +0100 |
---|---|---|
committer | Ludovic Courtès <ludo@gnu.org> | 2015-11-12 23:47:01 +0100 |
commit | 1b9aefa394a57dabe38e0658a3b612e962d3fc5e (patch) | |
tree | 999fae829bfdf0956e49ee56939f97e1f42fb8a4 /guix/ftp-client.scm | |
parent | 60fd51222f9d7ec90bdad37bca921f40f7f5b104 (diff) | |
download | guix-patches-1b9aefa394a57dabe38e0658a3b612e962d3fc5e.tar guix-patches-1b9aefa394a57dabe38e0658a3b612e962d3fc5e.tar.gz |
download: Always use AI_ADDRCONFIG when resolving host names.
* guix/build/download.scm (open-socket-for-uri): Always pass
AI_ADDRCONFIG to 'getaddrinfo' as recommended in the fine Guile
manual.
* guix/ftp-client.scm (ftp-open): Ditto.
Diffstat (limited to 'guix/ftp-client.scm')
-rw-r--r-- | guix/ftp-client.scm | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/guix/ftp-client.scm b/guix/ftp-client.scm index 9ea878a145..f02d460061 100644 --- a/guix/ftp-client.scm +++ b/guix/ftp-client.scm @@ -134,7 +134,9 @@ TIMEOUT, an ETIMEDOUT error is raised." (define addresses (getaddrinfo host (if (number? port) (number->string port) port) - (if (number? port) AI_NUMERICSERV 0))) + (if (number? port) + (logior AI_ADDRCONFIG AI_NUMERICSERV) + AI_ADDRCONFIG))) (let loop ((addresses addresses)) (let* ((ai (car addresses)) |