summaryrefslogtreecommitdiff
path: root/lib/smtp.c
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2018-09-14 23:33:28 +0200
committerDaniel Stenberg <daniel@haxx.se>2018-09-22 11:58:10 +0200
commit46e164069d1a5230e4e64cbd2ff46c46cce056bb (patch)
tree140ba8a3d265bfb33f7db446d2b7b24616b5f6b0 /lib/smtp.c
parentf078361c0e2539689df9962f35ab22f8ea25afe9 (diff)
downloadgnurl-46e164069d1a5230e4e64cbd2ff46c46cce056bb.tar.gz
gnurl-46e164069d1a5230e4e64cbd2ff46c46cce056bb.tar.bz2
gnurl-46e164069d1a5230e4e64cbd2ff46c46cce056bb.zip
url: use the URL API internally as well
... to make it a truly unified URL parser. Closes #3017
Diffstat (limited to 'lib/smtp.c')
-rw-r--r--lib/smtp.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/lib/smtp.c b/lib/smtp.c
index 50c0b3477..587562306 100644
--- a/lib/smtp.c
+++ b/lib/smtp.c
@@ -1441,7 +1441,6 @@ static CURLcode smtp_regular_transfer(struct connectdata *conn,
static CURLcode smtp_setup_connection(struct connectdata *conn)
{
- struct Curl_easy *data = conn->data;
CURLcode result;
/* Clear the TLS upgraded flag */
@@ -1452,8 +1451,6 @@ static CURLcode smtp_setup_connection(struct connectdata *conn)
if(result)
return result;
- data->state.path++; /* don't include the initial slash */
-
return CURLE_OK;
}
@@ -1507,7 +1504,7 @@ static CURLcode smtp_parse_url_path(struct connectdata *conn)
/* The SMTP struct is already initialised in smtp_connect() */
struct Curl_easy *data = conn->data;
struct smtp_conn *smtpc = &conn->proto.smtpc;
- const char *path = data->state.path;
+ const char *path = &data->state.up.path[1]; /* skip leading path */
char localhost[HOSTNAME_MAX + 1];
/* Calculate the path if necessary */