aboutsummaryrefslogtreecommitdiffstats
path: root/src/post.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/post.c')
-rw-r--r--src/post.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/post.c b/src/post.c
index 202d1d9..f27ceae 100644
--- a/src/post.c
+++ b/src/post.c
@@ -93,6 +93,9 @@ post_status(const char *status, const char *scope, const char *media_id)
curl_easy_setopt(curl, CURLOPT_URL, url);
curl_easy_setopt(curl, CURLOPT_MIMEPOST, mime);
curl_easy_perform(curl);
+ curl_easy_cleanup(curl);
+ curl_slist_free_all(header_list);
+ curl_mime_free(mime);
/* The the url */
@@ -106,5 +109,8 @@ post_status(const char *status, const char *scope, const char *media_id)
free(url);
free(authorization_header);
free(chunk.response);
+ free(parsed_json);
+ free(json_url);
+
return 0;
}