Set timeout for HTTP get request

This commit is contained in:
2020-07-25 19:55:27 -04:00
parent 3015ef0ff4
commit 61de9e9f14
4 changed files with 8 additions and 7 deletions

View File

@@ -20,7 +20,7 @@ typedef struct {
struct mg_mgr mgr;
} subreq_ctx_t;
response_t *web_get(const char *url);
response_t *web_get(const char *url, int timeout);
response_t *web_post(const char * url, const char * data);
subreq_ctx_t *web_post_async(const char *url, const char *data);
response_t *web_put(const char *url, const char *data);