summaryrefslogtreecommitdiff
path: root/libs/libcurl/src/gopher.c
diff options
context:
space:
mode:
authordartraiden <wowemuh@gmail.com>2019-03-27 17:53:10 +0300
committerdartraiden <wowemuh@gmail.com>2019-03-27 17:55:46 +0300
commite41e0c05795b60cd749ae038cd96c966ec0c87bb (patch)
treee1f0d837b021bcd1db9c59c3c56c09e1871d3750 /libs/libcurl/src/gopher.c
parent1634710bb1c4860feda7bb703fd01f5b2c23695d (diff)
libcurl: update to 7.64.1
Diffstat (limited to 'libs/libcurl/src/gopher.c')
-rw-r--r--libs/libcurl/src/gopher.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/libs/libcurl/src/gopher.c b/libs/libcurl/src/gopher.c
index 485b4b79a0..b296c62d19 100644
--- a/libs/libcurl/src/gopher.c
+++ b/libs/libcurl/src/gopher.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2018, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2019, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -78,8 +78,6 @@ static CURLcode gopher_do(struct connectdata *conn, bool *done)
CURLcode result = CURLE_OK;
struct Curl_easy *data = conn->data;
curl_socket_t sockfd = conn->sock[FIRSTSOCKET];
-
- curl_off_t *bytecount = &data->req.bytecount;
char *gopherpath;
char *path = data->state.up.path;
char *query = data->state.up.query;
@@ -90,7 +88,10 @@ static CURLcode gopher_do(struct connectdata *conn, bool *done)
*done = TRUE; /* unconditionally */
- if(path && query)
+ /* path is guaranteed non-NULL */
+ DEBUGASSERT(path);
+
+ if(query)
gopherpath = aprintf("%s?%s", path, query);
else
gopherpath = strdup(path);
@@ -167,8 +168,7 @@ static CURLcode gopher_do(struct connectdata *conn, bool *done)
if(result)
return result;
- Curl_setup_transfer(conn, FIRSTSOCKET, -1, FALSE, bytecount,
- -1, NULL); /* no upload */
+ Curl_setup_transfer(data, FIRSTSOCKET, -1, FALSE, -1);
return CURLE_OK;
}
#endif /*CURL_DISABLE_GOPHER*/