From 0ca65138cf02d6c46e1857e911a142d08cdad761 Mon Sep 17 00:00:00 2001 From: ꦌꦫꦶꦏ꧀ꦦꦿꦧꦮꦑꦩꦭ꧀ Date: Thu, 17 Jun 2021 20:52:46 +0800 Subject: Container for post and callback --- icclient/typedefs.h | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'icclient') diff --git a/icclient/typedefs.h b/icclient/typedefs.h index 2b0ec21..fbfa0d0 100644 --- a/icclient/typedefs.h +++ b/icclient/typedefs.h @@ -4,15 +4,30 @@ #ifdef __cplusplus #include #endif + #ifdef __EMSCRIPTEN__ + #include + typedef emscripten_fetch_t icclient_fetch_t; +typedef char icclient_post; + #else + +#include + typedef struct { void *userData; char *data; size_t numBytes; } icclient_fetch_t; +typedef struct curl_httppost icclient_post; + #endif +struct icclient_post_callback { + icclient_post *post; + void (*callback)(icclient_fetch_t *); +}; + #endif -- cgit v1.3