* the JSON we received was malformed).
* @return NULL if downloading a JSON reply failed.
*/
-void *
+static void *
download_get_result (struct GNUNET_CURL_DownloadBuffer *db,
CURL *eh,
long *response_code)
GNUNET_CURL_ResponseCleaner rc)
{
CURLMsg *cmsg;
- struct GNUNET_CURL_Job *job;
int n_running;
int n_completed;
- long response_code;
- void *response;
(void) curl_multi_perform (ctx->multi, &n_running);
while (NULL != (cmsg = curl_multi_info_read (ctx->multi, &n_completed)))
{
+ struct GNUNET_CURL_Job *job;
+ long response_code;
+ void *response;
+
/* Only documented return value is CURLMSG_DONE */
GNUNET_break (CURLMSG_DONE == cmsg->msg);
GNUNET_assert (CURLE_OK == curl_easy_getinfo (cmsg->easy_handle,
void
GNUNET_CURL_perform (struct GNUNET_CURL_Context *ctx)
{
-
GNUNET_CURL_perform2 (ctx,
- download_get_result,
+ &download_get_result,
(GNUNET_CURL_ResponseCleaner) &json_decref);
}