Skip to content

Commit

Permalink
quic: first code that actually uses ngtcp2
Browse files Browse the repository at this point in the history
Heavily based on the client.cc ngtcp2 example (there are no API docs
yet), this is my first code dump that has ngtcp2-using code.

There is missing code implementation that prevent this code from even
trying to function. Some of them marked with comments.
  • Loading branch information
bagder committed Dec 13, 2018
1 parent 625848b commit 7e72dd7
Show file tree
Hide file tree
Showing 7 changed files with 1,517 additions and 4 deletions.
5 changes: 3 additions & 2 deletions lib/Makefile.inc
Expand Up @@ -55,7 +55,7 @@ LIB_CFILES = file.c timeval.c base64.c hostip.c progress.c formdata.c \
curl_multibyte.c hostcheck.c conncache.c pipeline.c dotdot.c \
x509asn1.c http2.c smb.c curl_endian.c curl_des.c system_win32.c \
mime.c sha256.c setopt.c curl_path.c curl_ctype.c curl_range.c psl.c \
doh.c urlapi.c quic.c
doh.c urlapi.c quic.c quic-crypto.c

LIB_HFILES = arpa_telnet.h netrc.h file.h timeval.h hostip.h progress.h \
formdata.h cookie.h http.h sendf.h ftp.h url.h dict.h if2ip.h \
Expand All @@ -75,7 +75,8 @@ LIB_HFILES = arpa_telnet.h netrc.h file.h timeval.h hostip.h progress.h \
curl_setup_once.h multihandle.h setup-vms.h pipeline.h dotdot.h \
x509asn1.h http2.h sigpipe.h smb.h curl_endian.h curl_des.h \
curl_printf.h system_win32.h rand.h mime.h curl_sha256.h setopt.h \
curl_path.h curl_ctype.h curl_range.h psl.h doh.h urlapi-int.h quic.h
curl_path.h curl_ctype.h curl_range.h psl.h doh.h urlapi-int.h quic.h \
quic-crypto.h

LIB_RCFILES = libcurl.rc

Expand Down
3 changes: 2 additions & 1 deletion lib/hostip6.c
Expand Up @@ -163,7 +163,8 @@ Curl_addrinfo *Curl_getaddrinfo(struct connectdata *conn,

memset(&hints, 0, sizeof(hints));
hints.ai_family = pf;
hints.ai_socktype = conn->socktype;
hints.ai_socktype = (conn->transport == TRNSPRT_TCP) ?
SOCK_STREAM : SOCK_DGRAM;

#ifndef USE_RESOLVE_ON_IPS
/*
Expand Down

0 comments on commit 7e72dd7

Please sign in to comment.