mirror of
https://github.com/moparisthebest/curl
synced 2025-02-28 17:31:46 -05:00
http2: unify http_conn variable names to 'c'
This commit is contained in:
parent
09a31fabe4
commit
54c394699d
20
lib/http2.c
20
lib/http2.c
@ -48,7 +48,7 @@ static int http2_perform_getsock(const struct connectdata *conn,
|
|||||||
sockets */
|
sockets */
|
||||||
int numsocks)
|
int numsocks)
|
||||||
{
|
{
|
||||||
const struct http_conn *httpc = &conn->proto.httpc;
|
const struct http_conn *c = &conn->proto.httpc;
|
||||||
int bitmap = GETSOCK_BLANK;
|
int bitmap = GETSOCK_BLANK;
|
||||||
(void)numsocks;
|
(void)numsocks;
|
||||||
|
|
||||||
@ -56,10 +56,10 @@ static int http2_perform_getsock(const struct connectdata *conn,
|
|||||||
because of renegotiation. */
|
because of renegotiation. */
|
||||||
sock[0] = conn->sock[FIRSTSOCKET];
|
sock[0] = conn->sock[FIRSTSOCKET];
|
||||||
|
|
||||||
if(nghttp2_session_want_read(httpc->h2))
|
if(nghttp2_session_want_read(c->h2))
|
||||||
bitmap |= GETSOCK_READSOCK(FIRSTSOCKET);
|
bitmap |= GETSOCK_READSOCK(FIRSTSOCKET);
|
||||||
|
|
||||||
if(nghttp2_session_want_write(httpc->h2))
|
if(nghttp2_session_want_write(c->h2))
|
||||||
bitmap |= GETSOCK_WRITESOCK(FIRSTSOCKET);
|
bitmap |= GETSOCK_WRITESOCK(FIRSTSOCKET);
|
||||||
|
|
||||||
return bitmap;
|
return bitmap;
|
||||||
@ -76,17 +76,17 @@ static int http2_getsock(struct connectdata *conn,
|
|||||||
static CURLcode http2_disconnect(struct connectdata *conn,
|
static CURLcode http2_disconnect(struct connectdata *conn,
|
||||||
bool dead_connection)
|
bool dead_connection)
|
||||||
{
|
{
|
||||||
struct http_conn *httpc = &conn->proto.httpc;
|
struct http_conn *c = &conn->proto.httpc;
|
||||||
(void)dead_connection;
|
(void)dead_connection;
|
||||||
|
|
||||||
DEBUGF(infof(conn->data, "HTTP/2 DISCONNECT starts now\n"));
|
DEBUGF(infof(conn->data, "HTTP/2 DISCONNECT starts now\n"));
|
||||||
|
|
||||||
nghttp2_session_del(httpc->h2);
|
nghttp2_session_del(c->h2);
|
||||||
|
|
||||||
Curl_safefree(httpc->header_recvbuf->buffer);
|
Curl_safefree(c->header_recvbuf->buffer);
|
||||||
Curl_safefree(httpc->header_recvbuf);
|
Curl_safefree(c->header_recvbuf);
|
||||||
|
|
||||||
Curl_safefree(httpc->inbuf);
|
Curl_safefree(c->inbuf);
|
||||||
|
|
||||||
DEBUGF(infof(conn->data, "HTTP/2 DISCONNECT done\n"));
|
DEBUGF(infof(conn->data, "HTTP/2 DISCONNECT done\n"));
|
||||||
|
|
||||||
@ -158,14 +158,14 @@ static ssize_t send_callback(nghttp2_session *h2,
|
|||||||
void *userp)
|
void *userp)
|
||||||
{
|
{
|
||||||
struct connectdata *conn = (struct connectdata *)userp;
|
struct connectdata *conn = (struct connectdata *)userp;
|
||||||
struct http_conn *httpc = &conn->proto.httpc;
|
struct http_conn *c = &conn->proto.httpc;
|
||||||
ssize_t written;
|
ssize_t written;
|
||||||
CURLcode result = CURLE_OK;
|
CURLcode result = CURLE_OK;
|
||||||
|
|
||||||
(void)h2;
|
(void)h2;
|
||||||
(void)flags;
|
(void)flags;
|
||||||
|
|
||||||
written = ((Curl_send*)httpc->send_underlying)(conn, FIRSTSOCKET,
|
written = ((Curl_send*)c->send_underlying)(conn, FIRSTSOCKET,
|
||||||
data, length, &result);
|
data, length, &result);
|
||||||
|
|
||||||
if(result == CURLE_AGAIN) {
|
if(result == CURLE_AGAIN) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user