Fix issue 1446: honor ports given in SRV responses.
authorDavid Shaw <dshaw@jabberwocky.com>
Sat, 15 Dec 2012 15:11:11 +0000 (10:11 -0500)
committerDavid Shaw <dshaw@jabberwocky.com>
Sat, 15 Dec 2012 15:11:11 +0000 (10:11 -0500)
commitba9e974f1fd85b3dbbfb5e26d7a14f71d07c7cf2
tree0d0f0b4e7334ac9cb04759f9ed67188762f5aa5d
parent3e7cc25d4a574d27e08322d9e82915ddcb8416f1
Fix issue 1446: honor ports given in SRV responses.

* common/http.c (send_request, connect_server, http_open): Use a
  struct srv instead of a single srvtag so we can pass the chosen host
  and port back to the caller.
  (connect_server): Use the proper port in the HAVE_GETADDRINFO case.

* keyserver/curl-shim.c (curl_easy_perform): Use struct srv and log
  chosen host and port.

* keyserver/gpgkeys_hkp.c (main): Properly take the port given by SRV.
common/http.c
common/http.h
keyserver/curl-shim.c
keyserver/gpgkeys_hkp.c