summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorꦌꦫꦶꦏ꧀ꦦꦿꦧꦮꦑꦩꦭ꧀ <erik@darapsa.co.id>2021-06-18 10:22:41 +0800
committerꦌꦫꦶꦏ꧀ꦦꦿꦧꦮꦑꦩꦭ꧀ <erik@darapsa.co.id>2021-06-18 10:22:41 +0800
commit9ada6a6b80e0708d253e658ce5a670c93d94015b (patch)
tree0a9434faf80998cdaf7c53107ed3fe50aa2039b6
parentfc634eb41958aa8e0b57ca2ce157b563b3aed9af (diff)
Especially on Emscripten, post is pointed by userData, to be freed later
-rw-r--r--client.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/client.c b/client.c
index b43d1c5..436ae99 100644
--- a/client.c
+++ b/client.c
@@ -97,11 +97,10 @@ void icclient_free_catalog(struct icclient_catalog *catalog)
void icclient_free_response(icclient_response *response)
{
-#ifdef __EMSCRIPTEN__
- emscripten_fetch_close(response);
-#else
if (response->userData)
free(response->userData);
+#ifdef __EMSCRIPTEN__
+ emscripten_fetch_close(response);
#endif
}