aboutsummaryrefslogtreecommitdiff
path: root/lib/hostip6.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/hostip6.c')
-rw-r--r--lib/hostip6.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/lib/hostip6.c b/lib/hostip6.c
index 4624e00b8..be86a5136 100644
--- a/lib/hostip6.c
+++ b/lib/hostip6.c
@@ -252,10 +252,7 @@ Curl_addrinfo *Curl_getaddrinfo(struct connectdata *conn,
memset(&hints, 0, sizeof(hints));
hints.ai_family = pf;
- if(conn->protocol & PROT_TFTP)
- hints.ai_socktype = SOCK_DGRAM;
- else
- hints.ai_socktype = SOCK_STREAM;
+ hints.ai_socktype = conn->socktype;
hints.ai_flags = ai_flags;
snprintf(sbuf, sizeof(sbuf), "%d", port);