Lines Matching refs:port
104 static void wget_info(char *url, char **host, char **port, char **path)
117 *port = strafter(*host, "]:");
121 if ((*port = strchr(*host, ':'))) {
122 **port = '\0';
123 *port = *port + 1;
127 if (!*port && WGET_IS_HTTP) *port = "80";
128 else if (!*port && WGET_IS_HTTPS) *port = "443";
129 else if (!*port) error_exit("unsupported protocol");
132 static void wget_connect(char *host, char *port)
136 xgetaddrinfo(host, port, AF_UNSPEC, SOCK_STREAM, 0, 0);
154 if (tls_connect(TT.tls, host, port) != 0)
166 xgetaddrinfo(host, port, AF_UNSPEC, SOCK_STREAM, 0, 0);
278 char *body, *index, *host, *port, *path;
286 wget_info(TT.url, &host, &port, &path);
293 wget_connect(host, port);