Loading lib/http.h +2 −6 Original line number Diff line number Diff line Loading @@ -186,9 +186,6 @@ struct HTTP { #endif }; typedef int (*sending)(void); /* Curl_send */ typedef int (*recving)(void); /* Curl_recv */ #ifdef USE_NGHTTP2 /* h2 settings for this connection */ struct h2settings { Loading @@ -197,15 +194,14 @@ struct h2settings { }; #endif struct http_conn { #ifdef USE_NGHTTP2 #define H2_BINSETTINGS_LEN 80 nghttp2_session *h2; uint8_t binsettings[H2_BINSETTINGS_LEN]; size_t binlen; /* length of the binsettings data */ sending send_underlying; /* underlying send Curl_send callback */ recving recv_underlying; /* underlying recv Curl_recv callback */ Curl_send *send_underlying; /* underlying send Curl_send callback */ Curl_recv *recv_underlying; /* underlying recv Curl_recv callback */ char *inbuf; /* buffer to receive data from underlying socket */ size_t inbuflen; /* number of bytes filled in inbuf */ size_t nread_inbuf; /* number of bytes read from in inbuf */ Loading lib/http2.c +2 −2 Original line number Diff line number Diff line Loading @@ -2141,8 +2141,8 @@ CURLcode Curl_http2_switched(struct connectdata *conn, if(result) return result; httpc->recv_underlying = (recving)conn->recv[FIRSTSOCKET]; httpc->send_underlying = (sending)conn->send[FIRSTSOCKET]; httpc->recv_underlying = conn->recv[FIRSTSOCKET]; httpc->send_underlying = conn->send[FIRSTSOCKET]; conn->recv[FIRSTSOCKET] = http2_recv; conn->send[FIRSTSOCKET] = http2_send; Loading lib/urldata.h +14 −14 Original line number Diff line number Diff line Loading @@ -98,6 +98,20 @@ #include "hash.h" #include "splay.h" /* return the count of bytes sent, or -1 on error */ typedef ssize_t (Curl_send)(struct connectdata *conn, /* connection data */ int sockindex, /* socketindex */ const void *buf, /* data to write */ size_t len, /* max amount to write */ CURLcode *err); /* error to return */ /* return the count of bytes read, or -1 on error */ typedef ssize_t (Curl_recv)(struct connectdata *conn, /* connection data */ int sockindex, /* socketindex */ char *buf, /* store data here */ size_t len, /* max amount to read */ CURLcode *err); /* error to return */ #include "mime.h" #include "imap.h" #include "pop3.h" Loading Loading @@ -704,20 +718,6 @@ struct Curl_handler { #define CONNRESULT_NONE 0 /* No extra information. */ #define CONNRESULT_DEAD (1<<0) /* The connection is dead. */ /* return the count of bytes sent, or -1 on error */ typedef ssize_t (Curl_send)(struct connectdata *conn, /* connection data */ int sockindex, /* socketindex */ const void *buf, /* data to write */ size_t len, /* max amount to write */ CURLcode *err); /* error to return */ /* return the count of bytes read, or -1 on error */ typedef ssize_t (Curl_recv)(struct connectdata *conn, /* connection data */ int sockindex, /* socketindex */ char *buf, /* store data here */ size_t len, /* max amount to read */ CURLcode *err); /* error to return */ #ifdef USE_RECV_BEFORE_SEND_WORKAROUND struct postponed_data { char *buffer; /* Temporal store for received data during Loading Loading
lib/http.h +2 −6 Original line number Diff line number Diff line Loading @@ -186,9 +186,6 @@ struct HTTP { #endif }; typedef int (*sending)(void); /* Curl_send */ typedef int (*recving)(void); /* Curl_recv */ #ifdef USE_NGHTTP2 /* h2 settings for this connection */ struct h2settings { Loading @@ -197,15 +194,14 @@ struct h2settings { }; #endif struct http_conn { #ifdef USE_NGHTTP2 #define H2_BINSETTINGS_LEN 80 nghttp2_session *h2; uint8_t binsettings[H2_BINSETTINGS_LEN]; size_t binlen; /* length of the binsettings data */ sending send_underlying; /* underlying send Curl_send callback */ recving recv_underlying; /* underlying recv Curl_recv callback */ Curl_send *send_underlying; /* underlying send Curl_send callback */ Curl_recv *recv_underlying; /* underlying recv Curl_recv callback */ char *inbuf; /* buffer to receive data from underlying socket */ size_t inbuflen; /* number of bytes filled in inbuf */ size_t nread_inbuf; /* number of bytes read from in inbuf */ Loading
lib/http2.c +2 −2 Original line number Diff line number Diff line Loading @@ -2141,8 +2141,8 @@ CURLcode Curl_http2_switched(struct connectdata *conn, if(result) return result; httpc->recv_underlying = (recving)conn->recv[FIRSTSOCKET]; httpc->send_underlying = (sending)conn->send[FIRSTSOCKET]; httpc->recv_underlying = conn->recv[FIRSTSOCKET]; httpc->send_underlying = conn->send[FIRSTSOCKET]; conn->recv[FIRSTSOCKET] = http2_recv; conn->send[FIRSTSOCKET] = http2_send; Loading
lib/urldata.h +14 −14 Original line number Diff line number Diff line Loading @@ -98,6 +98,20 @@ #include "hash.h" #include "splay.h" /* return the count of bytes sent, or -1 on error */ typedef ssize_t (Curl_send)(struct connectdata *conn, /* connection data */ int sockindex, /* socketindex */ const void *buf, /* data to write */ size_t len, /* max amount to write */ CURLcode *err); /* error to return */ /* return the count of bytes read, or -1 on error */ typedef ssize_t (Curl_recv)(struct connectdata *conn, /* connection data */ int sockindex, /* socketindex */ char *buf, /* store data here */ size_t len, /* max amount to read */ CURLcode *err); /* error to return */ #include "mime.h" #include "imap.h" #include "pop3.h" Loading Loading @@ -704,20 +718,6 @@ struct Curl_handler { #define CONNRESULT_NONE 0 /* No extra information. */ #define CONNRESULT_DEAD (1<<0) /* The connection is dead. */ /* return the count of bytes sent, or -1 on error */ typedef ssize_t (Curl_send)(struct connectdata *conn, /* connection data */ int sockindex, /* socketindex */ const void *buf, /* data to write */ size_t len, /* max amount to write */ CURLcode *err); /* error to return */ /* return the count of bytes read, or -1 on error */ typedef ssize_t (Curl_recv)(struct connectdata *conn, /* connection data */ int sockindex, /* socketindex */ char *buf, /* store data here */ size_t len, /* max amount to read */ CURLcode *err); /* error to return */ #ifdef USE_RECV_BEFORE_SEND_WORKAROUND struct postponed_data { char *buffer; /* Temporal store for received data during Loading