summaryrefslogtreecommitdiff
path: root/lib/transfer.c
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2020-11-23 08:32:41 +0100
committerDaniel Stenberg <daniel@haxx.se>2020-11-23 16:16:16 +0100
commita95a6ce6b809693a1195e3b4347a6cfa0fbc2ee7 (patch)
tree5f0b777ade4540e7c622b6ad2d2126d920dafa6b /lib/transfer.c
parent5c8849cede5577b8b23c3b1d75c03923ce034061 (diff)
downloadcurl-a95a6ce6b809693a1195e3b4347a6cfa0fbc2ee7.tar.gz
urldata: remove 'void *protop' and create the union 'p'
... to avoid the use of 'void *' for the protocol specific structs done per transfer. Closes #6238
Diffstat (limited to 'lib/transfer.c')
-rw-r--r--lib/transfer.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/transfer.c b/lib/transfer.c
index 95fd99a6e..bfd0218fe 100644
--- a/lib/transfer.c
+++ b/lib/transfer.c
@@ -168,7 +168,7 @@ CURLcode Curl_fillreadbuffer(struct connectdata *conn, size_t bytes,
bool sending_http_headers = FALSE;
if(conn->handler->protocol&(PROTO_FAMILY_HTTP|CURLPROTO_RTSP)) {
- const struct HTTP *http = data->req.protop;
+ const struct HTTP *http = data->req.p.http;
if(http->sending == HTTPSEND_REQUEST)
/* We're sending the HTTP request headers, not the data.
@@ -427,7 +427,7 @@ CURLcode Curl_readrewind(struct connectdata *conn)
CURLOPT_HTTPPOST, call app to rewind
*/
if(conn->handler->protocol & PROTO_FAMILY_HTTP) {
- struct HTTP *http = data->req.protop;
+ struct HTTP *http = data->req.p.http;
if(http->sendit)
mimepart = http->sendit;
@@ -1029,7 +1029,7 @@ static CURLcode readwrite_upload(struct Curl_easy *data,
/* HTTP pollution, this should be written nicer to become more
protocol agnostic. */
size_t fillcount;
- struct HTTP *http = k->protop;
+ struct HTTP *http = k->p.http;
if((k->exp100 == EXP100_SENDING_REQUEST) &&
(http->sending == HTTPSEND_BODY)) {
@@ -1854,7 +1854,7 @@ Curl_setup_transfer(
{
struct SingleRequest *k = &data->req;
struct connectdata *conn = data->conn;
- struct HTTP *http = data->req.protop;
+ struct HTTP *http = data->req.p.http;
bool httpsending = ((conn->handler->protocol&PROTO_FAMILY_HTTP) &&
(http->sending == HTTPSEND_REQUEST));
DEBUGASSERT(conn != NULL);