ses->pending_inbound_msg->buf = GNUNET_malloc(GNUNET_SERVER_MAX_MESSAGE_SIZE);
ses->pending_inbound_msg->len = GNUNET_SERVER_MAX_MESSAGE_SIZE;
ses->pending_inbound_msg->pos = 0;
-
-
return ses;
}
return MHD_YES;
}
-
-int serror;
-
/**
* Process GET or PUT request received via MHD. For
* GET, queue response that will send back our pending
static void send_execute (void *cls,
const struct GNUNET_SCHEDULER_TaskContext *tc)
{
-
+ static unsigned int handles_last_run;
int running;
struct CURLMsg *msg;
CURLMcode mret;
{
running = 0;
mret = curl_multi_perform (multi_handle, &running);
- if (running == 0)
+ if (running < handles_last_run)
{
do
{
}
while ( (running > 0) );
}
+ handles_last_run = running;
}
while (mret == CURLM_CALL_MULTI_PERFORM);
send_prepare(cls);
http_daemon_v6 = NULL;
}
- mret = curl_multi_cleanup(multi_handle);
- if ( CURLM_OK != mret)
- GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,"curl multihandle clean up failed");
-
/* free all sessions */
cs = plugin->sessions;
cs = cs_next;
}
+ mret = curl_multi_cleanup(multi_handle);
+ if ( CURLM_OK != mret)
+ GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,"curl multihandle clean up failed");
+
GNUNET_free (plugin);
GNUNET_free (api);
return NULL;