commit 94a07f9
grunfink
·
2025-04-27 04:01:05 +0000 UTC
parent 08dc429
Fixed length error in xs_smtp_request().
1 files changed,
+2,
-1
+2,
-1
1@@ -200,6 +200,7 @@ xs_dict *xs_http_request(const char *method, const char *url,
2 return response;
3 }
4
5+
6 int xs_smtp_request(const char *url, const char *user, const char *pass,
7 const char *from, const char *to, const xs_str *body,
8 int use_ssl)
9@@ -209,7 +210,7 @@ int xs_smtp_request(const char *url, const char *user, const char *pass,
10 struct curl_slist *rcpt = NULL;
11 struct _payload_data pd = {
12 .data = (char *)body,
13- .size = xs_size(body),
14+ .size = strlen(body),
15 .offset = 0
16 };
17