Browse Source

don't send Transfer-Encoding: chunked for newer libcurl

master
orignal 2 years ago
parent
commit
8263397fa1
  1. 18
      util.c

18
util.c

@ -61,24 +61,6 @@ static size_t all_data_cb(const void *ptr, size_t size, size_t nmemb, @@ -61,24 +61,6 @@ static size_t all_data_cb(const void *ptr, size_t size, size_t nmemb,
return len;
}
static size_t upload_data_cb(void *ptr, size_t size, size_t nmemb,
void *user_data)
{
struct upload_buffer *ub = user_data;
int len = size * nmemb;
if (len > ub->len)
len = ub->len;
if (len) {
memcpy(ptr, ub->buf, len);
ub->buf += len;
ub->len -= len;
}
return len;
}
json_t *json_rpc_call(const char *url, const char *userpass, const char *rpc_req)
{
CURL *curl;

Loading…
Cancel
Save