From ac4aa1e741bd15d33bdaa959be1a73732eda8359 Mon Sep 17 00:00:00 2001 From: ꦌꦫꦶꦏ꧀ꦦꦿꦧꦮꦑꦩꦭ꧀ Date: Sun, 20 Jun 2021 08:44:36 +0800 Subject: Make sure the post in the container is NULL too when it needs to be --- request.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/request.c b/request.c index 8668f4b..f61d4e8 100644 --- a/request.c +++ b/request.c @@ -170,7 +170,7 @@ void request(void (*handler)(icclient_response *), void (*callback)(void *), str curl_easy_setopt(curl, CURLOPT_HTTPGET, 1L); struct container *container = malloc(sizeof(struct container)); container->curl = curl; - container->post = post; + container->post = post ? post : NULL; container->handler = handler; container->response = response; thrd_t thread; -- cgit v1.3