diff options
Diffstat (limited to 'src/transport/plugin_transport_http_client.c')
-rw-r--r-- | src/transport/plugin_transport_http_client.c | 181 |
1 files changed, 91 insertions, 90 deletions
diff --git a/src/transport/plugin_transport_http_client.c b/src/transport/plugin_transport_http_client.c index a2024953c..62be281ab 100644 --- a/src/transport/plugin_transport_http_client.c +++ b/src/transport/plugin_transport_http_client.c | |||
@@ -52,11 +52,11 @@ client_log (CURL * curl, curl_infotype type, char *data, size_t size, void *cls) | |||
52 | text[size + 1] = '\0'; | 52 | text[size + 1] = '\0'; |
53 | } | 53 | } |
54 | #if BUILD_HTTPS | 54 | #if BUILD_HTTPS |
55 | GNUNET_log_from (GNUNET_ERROR_TYPE_DEBUG, | 55 | GNUNET_log_from (GNUNET_ERROR_TYPE_DEBUG, "transport-https", |
56 | "transport-https", "Client: %X - %s", cls, text); | 56 | "Client: %X - %s", cls, text); |
57 | #else | 57 | #else |
58 | GNUNET_log_from (GNUNET_ERROR_TYPE_DEBUG, | 58 | GNUNET_log_from (GNUNET_ERROR_TYPE_DEBUG, "transport-http", |
59 | "transport-http", "Client: %X - %s", cls, text); | 59 | "Client: %X - %s", cls, text); |
60 | #endif | 60 | #endif |
61 | } | 61 | } |
62 | return 0; | 62 | return 0; |
@@ -91,7 +91,7 @@ client_schedule (struct Plugin *plugin, int now) | |||
91 | struct GNUNET_TIME_Relative timeout; | 91 | struct GNUNET_TIME_Relative timeout; |
92 | 92 | ||
93 | /* Cancel previous scheduled task */ | 93 | /* Cancel previous scheduled task */ |
94 | if (plugin->client_perform_task!= GNUNET_SCHEDULER_NO_TASK) | 94 | if (plugin->client_perform_task != GNUNET_SCHEDULER_NO_TASK) |
95 | { | 95 | { |
96 | GNUNET_SCHEDULER_cancel (plugin->client_perform_task); | 96 | GNUNET_SCHEDULER_cancel (plugin->client_perform_task); |
97 | plugin->client_perform_task = GNUNET_SCHEDULER_NO_TASK; | 97 | plugin->client_perform_task = GNUNET_SCHEDULER_NO_TASK; |
@@ -132,12 +132,8 @@ client_schedule (struct Plugin *plugin, int now) | |||
132 | 132 | ||
133 | plugin->client_perform_task = | 133 | plugin->client_perform_task = |
134 | GNUNET_SCHEDULER_add_select (GNUNET_SCHEDULER_PRIORITY_DEFAULT, | 134 | GNUNET_SCHEDULER_add_select (GNUNET_SCHEDULER_PRIORITY_DEFAULT, |
135 | GNUNET_SCHEDULER_NO_TASK, | 135 | GNUNET_SCHEDULER_NO_TASK, timeout, grs, gws, |
136 | timeout, | 136 | &client_run, plugin); |
137 | grs, | ||
138 | gws, | ||
139 | &client_run, | ||
140 | plugin); | ||
141 | GNUNET_NETWORK_fdset_destroy (gws); | 137 | GNUNET_NETWORK_fdset_destroy (gws); |
142 | GNUNET_NETWORK_fdset_destroy (grs); | 138 | GNUNET_NETWORK_fdset_destroy (grs); |
143 | return GNUNET_OK; | 139 | return GNUNET_OK; |
@@ -153,10 +149,10 @@ client_send (struct Session *s, struct HTTP_Message *msg) | |||
153 | { | 149 | { |
154 | #if VERBOSE_CLIENT | 150 | #if VERBOSE_CLIENT |
155 | GNUNET_log_from (GNUNET_ERROR_TYPE_DEBUG, s->plugin->name, | 151 | GNUNET_log_from (GNUNET_ERROR_TYPE_DEBUG, s->plugin->name, |
156 | "Client: %X was suspended, unpausing\n", s->client_put); | 152 | "Client: %X was suspended, unpausing\n", s->client_put); |
157 | #endif | 153 | #endif |
158 | s->client_put_paused = GNUNET_NO; | 154 | s->client_put_paused = GNUNET_NO; |
159 | curl_easy_pause(s->client_put, CURLPAUSE_CONT); | 155 | curl_easy_pause (s->client_put, CURLPAUSE_CONT); |
160 | } | 156 | } |
161 | 157 | ||
162 | client_schedule (s->plugin, GNUNET_YES); | 158 | client_schedule (s->plugin, GNUNET_YES); |
@@ -189,43 +185,45 @@ client_run (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
189 | running = 0; | 185 | running = 0; |
190 | mret = curl_multi_perform (plugin->client_mh, &running); | 186 | mret = curl_multi_perform (plugin->client_mh, &running); |
191 | 187 | ||
192 | CURLMsg * msg; | 188 | CURLMsg *msg; |
193 | int msgs_left; | 189 | int msgs_left; |
194 | while ((msg = curl_multi_info_read(plugin->client_mh, &msgs_left))) | 190 | |
191 | while ((msg = curl_multi_info_read (plugin->client_mh, &msgs_left))) | ||
195 | { | 192 | { |
196 | CURL *easy_h = msg->easy_handle; | 193 | CURL *easy_h = msg->easy_handle; |
197 | struct Session *s = NULL; | 194 | struct Session *s = NULL; |
198 | char * d = (char *) s; | 195 | char *d = (char *) s; |
199 | 196 | ||
200 | 197 | ||
201 | //GNUNET_assert (easy_h != NULL); | 198 | //GNUNET_assert (easy_h != NULL); |
202 | if (easy_h == NULL) | 199 | if (easy_h == NULL) |
203 | { | 200 | { |
204 | GNUNET_log_from (GNUNET_ERROR_TYPE_DEBUG, plugin->name, | 201 | GNUNET_log_from (GNUNET_ERROR_TYPE_DEBUG, plugin->name, |
205 | "Client: connection to ended with reason %i: `%s', %i handles running\n", | 202 | "Client: connection to ended with reason %i: `%s', %i handles running\n", |
206 | msg->data.result, | 203 | msg->data.result, |
207 | curl_easy_strerror(msg->data.result), | 204 | curl_easy_strerror (msg->data.result), running); |
208 | running); | 205 | continue; |
209 | continue; | 206 | } |
210 | } | 207 | |
211 | 208 | GNUNET_assert (CURLE_OK == | |
212 | GNUNET_assert (CURLE_OK == curl_easy_getinfo(easy_h, CURLINFO_PRIVATE, &d)); | 209 | curl_easy_getinfo (easy_h, CURLINFO_PRIVATE, &d)); |
213 | s = (struct Session *) d; | 210 | s = (struct Session *) d; |
214 | GNUNET_assert (s != NULL); | 211 | GNUNET_assert (s != NULL); |
215 | 212 | ||
216 | if (msg->msg == CURLMSG_DONE) | 213 | if (msg->msg == CURLMSG_DONE) |
217 | { | 214 | { |
218 | GNUNET_log_from (GNUNET_ERROR_TYPE_DEBUG, plugin->name, | 215 | GNUNET_log_from (GNUNET_ERROR_TYPE_DEBUG, plugin->name, |
219 | "Client: %X connection to '%s' %s ended with reason %i: `%s'\n", | 216 | "Client: %X connection to '%s' %s ended with reason %i: `%s'\n", |
220 | msg->easy_handle, GNUNET_i2s(&s->target), | 217 | msg->easy_handle, GNUNET_i2s (&s->target), |
221 | http_plugin_address_to_string (NULL, s->addr, s->addrlen), | 218 | http_plugin_address_to_string (NULL, s->addr, |
222 | msg->data.result, | 219 | s->addrlen), |
223 | curl_easy_strerror(msg->data.result)); | 220 | msg->data.result, |
224 | 221 | curl_easy_strerror (msg->data.result)); | |
225 | client_disconnect(s); | 222 | |
226 | //GNUNET_log_from (GNUNET_ERROR_TYPE_DEBUG, plugin->name,"Notifying about ended session to peer `%s' `%s'\n", GNUNET_i2s (&s->target), http_plugin_address_to_string (plugin, s->addr, s->addrlen)); | 223 | client_disconnect (s); |
227 | notify_session_end (plugin, &s->target, s); | 224 | //GNUNET_log_from (GNUNET_ERROR_TYPE_DEBUG, plugin->name,"Notifying about ended session to peer `%s' `%s'\n", GNUNET_i2s (&s->target), http_plugin_address_to_string (plugin, s->addr, s->addrlen)); |
228 | } | 225 | notify_session_end (plugin, &s->target, s); |
226 | } | ||
229 | } | 227 | } |
230 | } | 228 | } |
231 | while (mret == CURLM_CALL_MULTI_PERFORM); | 229 | while (mret == CURLM_CALL_MULTI_PERFORM); |
@@ -238,18 +236,17 @@ client_disconnect (struct Session *s) | |||
238 | int res = GNUNET_OK; | 236 | int res = GNUNET_OK; |
239 | CURLMcode mret; | 237 | CURLMcode mret; |
240 | struct Plugin *plugin = s->plugin; | 238 | struct Plugin *plugin = s->plugin; |
241 | struct HTTP_Message * msg; | 239 | struct HTTP_Message *msg; |
242 | struct HTTP_Message * t; | 240 | struct HTTP_Message *t; |
243 | 241 | ||
244 | 242 | ||
245 | 243 | ||
246 | if (s->client_put != NULL) | 244 | if (s->client_put != NULL) |
247 | { | 245 | { |
248 | #if DEBUG_HTTP | 246 | #if DEBUG_HTTP |
249 | GNUNET_log_from (GNUNET_ERROR_TYPE_DEBUG, plugin->name, | 247 | GNUNET_log_from (GNUNET_ERROR_TYPE_DEBUG, plugin->name, |
250 | "Client: %X Deleting outbound PUT session to peer `%s'\n", | 248 | "Client: %X Deleting outbound PUT session to peer `%s'\n", |
251 | s->client_put, | 249 | s->client_put, GNUNET_i2s (&s->target)); |
252 | GNUNET_i2s (&s->target)); | ||
253 | #endif | 250 | #endif |
254 | 251 | ||
255 | mret = curl_multi_remove_handle (plugin->client_mh, s->client_put); | 252 | mret = curl_multi_remove_handle (plugin->client_mh, s->client_put); |
@@ -266,17 +263,16 @@ client_disconnect (struct Session *s) | |||
266 | 263 | ||
267 | if (s->recv_wakeup_task != GNUNET_SCHEDULER_NO_TASK) | 264 | if (s->recv_wakeup_task != GNUNET_SCHEDULER_NO_TASK) |
268 | { | 265 | { |
269 | GNUNET_SCHEDULER_cancel (s->recv_wakeup_task); | 266 | GNUNET_SCHEDULER_cancel (s->recv_wakeup_task); |
270 | s->recv_wakeup_task = GNUNET_SCHEDULER_NO_TASK; | 267 | s->recv_wakeup_task = GNUNET_SCHEDULER_NO_TASK; |
271 | } | 268 | } |
272 | 269 | ||
273 | if (s->client_get != NULL) | 270 | if (s->client_get != NULL) |
274 | { | 271 | { |
275 | #if DEBUG_HTTP | 272 | #if DEBUG_HTTP |
276 | GNUNET_log_from (GNUNET_ERROR_TYPE_DEBUG, plugin->name, | 273 | GNUNET_log_from (GNUNET_ERROR_TYPE_DEBUG, plugin->name, |
277 | "Client: %X Deleting outbound GET session to peer `%s'\n", | 274 | "Client: %X Deleting outbound GET session to peer `%s'\n", |
278 | s->client_get, | 275 | s->client_get, GNUNET_i2s (&s->target)); |
279 | GNUNET_i2s (&s->target)); | ||
280 | #endif | 276 | #endif |
281 | 277 | ||
282 | mret = curl_multi_remove_handle (plugin->client_mh, s->client_get); | 278 | mret = curl_multi_remove_handle (plugin->client_mh, s->client_get); |
@@ -296,7 +292,7 @@ client_disconnect (struct Session *s) | |||
296 | t = msg->next; | 292 | t = msg->next; |
297 | if (NULL != msg->transmit_cont) | 293 | if (NULL != msg->transmit_cont) |
298 | msg->transmit_cont (msg->transmit_cont_cls, &s->target, GNUNET_SYSERR); | 294 | msg->transmit_cont (msg->transmit_cont_cls, &s->target, GNUNET_SYSERR); |
299 | GNUNET_CONTAINER_DLL_remove(s->msg_head, s->msg_tail, msg); | 295 | GNUNET_CONTAINER_DLL_remove (s->msg_head, s->msg_tail, msg); |
300 | GNUNET_free (msg); | 296 | GNUNET_free (msg); |
301 | msg = t; | 297 | msg = t; |
302 | } | 298 | } |
@@ -316,24 +312,28 @@ client_disconnect (struct Session *s) | |||
316 | 312 | ||
317 | static void | 313 | static void |
318 | client_receive_mst_cb (void *cls, void *client, | 314 | client_receive_mst_cb (void *cls, void *client, |
319 | const struct GNUNET_MessageHeader *message) | 315 | const struct GNUNET_MessageHeader *message) |
320 | { | 316 | { |
321 | struct Session *s = cls; | 317 | struct Session *s = cls; |
322 | struct GNUNET_TIME_Relative delay; | 318 | struct GNUNET_TIME_Relative delay; |
323 | 319 | ||
324 | delay = http_plugin_receive (s, &s->target, message, s, s->addr, s->addrlen); | 320 | delay = http_plugin_receive (s, &s->target, message, s, s->addr, s->addrlen); |
325 | s->next_receive = GNUNET_TIME_absolute_add(GNUNET_TIME_absolute_get(), delay); | 321 | s->next_receive = |
322 | GNUNET_TIME_absolute_add (GNUNET_TIME_absolute_get (), delay); | ||
326 | 323 | ||
327 | if (GNUNET_TIME_absolute_get().abs_value < s->next_receive.abs_value) | 324 | if (GNUNET_TIME_absolute_get ().abs_value < s->next_receive.abs_value) |
328 | { | 325 | { |
329 | #if VERBOSE_CLIENT | 326 | #if VERBOSE_CLIENT |
330 | struct Plugin *plugin = s->plugin; | 327 | struct Plugin *plugin = s->plugin; |
328 | |||
331 | GNUNET_log_from (GNUNET_ERROR_TYPE_DEBUG, plugin->name, | 329 | GNUNET_log_from (GNUNET_ERROR_TYPE_DEBUG, plugin->name, |
332 | "Client: peer `%s' address `%s' next read delayed for %llu ms\n", | 330 | "Client: peer `%s' address `%s' next read delayed for %llu ms\n", |
333 | GNUNET_i2s (&s->target), GNUNET_a2s (s->addr, s->addrlen), delay); | 331 | GNUNET_i2s (&s->target), GNUNET_a2s (s->addr, s->addrlen), |
332 | delay); | ||
334 | #endif | 333 | #endif |
335 | } | 334 | } |
336 | } | 335 | } |
336 | |||
337 | static void | 337 | static void |
338 | client_wake_up (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | 338 | client_wake_up (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) |
339 | { | 339 | { |
@@ -345,11 +345,10 @@ client_wake_up (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
345 | return; | 345 | return; |
346 | 346 | ||
347 | GNUNET_log_from (GNUNET_ERROR_TYPE_DEBUG, s->plugin->name, | 347 | GNUNET_log_from (GNUNET_ERROR_TYPE_DEBUG, s->plugin->name, |
348 | "Client: %X Waking up receive handle\n", | 348 | "Client: %X Waking up receive handle\n", s->client_get); |
349 | s->client_get); | ||
350 | 349 | ||
351 | if (s->client_get != NULL) | 350 | if (s->client_get != NULL) |
352 | curl_easy_pause(s->client_get, CURLPAUSE_CONT); | 351 | curl_easy_pause (s->client_get, CURLPAUSE_CONT); |
353 | 352 | ||
354 | } | 353 | } |
355 | 354 | ||
@@ -372,37 +371,38 @@ client_receive (void *stream, size_t size, size_t nmemb, void *cls) | |||
372 | 371 | ||
373 | #if VERBOSE_CLIENT | 372 | #if VERBOSE_CLIENT |
374 | struct Plugin *plugin = s->plugin; | 373 | struct Plugin *plugin = s->plugin; |
374 | |||
375 | GNUNET_log_from (GNUNET_ERROR_TYPE_DEBUG, plugin->name, | 375 | GNUNET_log_from (GNUNET_ERROR_TYPE_DEBUG, plugin->name, |
376 | "Client: Received %Zu bytes from peer `%s'\n", | 376 | "Client: Received %Zu bytes from peer `%s'\n", len, |
377 | len, | ||
378 | GNUNET_i2s (&s->target)); | 377 | GNUNET_i2s (&s->target)); |
379 | #endif | 378 | #endif |
380 | 379 | ||
381 | now = GNUNET_TIME_absolute_get(); | 380 | now = GNUNET_TIME_absolute_get (); |
382 | if (now.abs_value < s->next_receive.abs_value) | 381 | if (now.abs_value < s->next_receive.abs_value) |
383 | { | 382 | { |
384 | struct GNUNET_TIME_Absolute now = GNUNET_TIME_absolute_get(); | 383 | struct GNUNET_TIME_Absolute now = GNUNET_TIME_absolute_get (); |
385 | struct GNUNET_TIME_Relative delta = GNUNET_TIME_absolute_get_difference(now, s->next_receive); | 384 | struct GNUNET_TIME_Relative delta = |
385 | GNUNET_TIME_absolute_get_difference (now, s->next_receive); | ||
386 | #if DEBUG_CLIENT | 386 | #if DEBUG_CLIENT |
387 | GNUNET_log_from (GNUNET_ERROR_TYPE_DEBUG, plugin->name, | 387 | GNUNET_log_from (GNUNET_ERROR_TYPE_DEBUG, plugin->name, |
388 | "Client: %X No inbound bandwidth available! Next read was delayed for %llu ms\n", | 388 | "Client: %X No inbound bandwidth available! Next read was delayed for %llu ms\n", |
389 | s->client_get, delta.rel_value); | 389 | s->client_get, delta.rel_value); |
390 | #endif | 390 | #endif |
391 | if (s->recv_wakeup_task != GNUNET_SCHEDULER_NO_TASK) | 391 | if (s->recv_wakeup_task != GNUNET_SCHEDULER_NO_TASK) |
392 | { | 392 | { |
393 | GNUNET_SCHEDULER_cancel (s->recv_wakeup_task); | 393 | GNUNET_SCHEDULER_cancel (s->recv_wakeup_task); |
394 | s->recv_wakeup_task = GNUNET_SCHEDULER_NO_TASK; | 394 | s->recv_wakeup_task = GNUNET_SCHEDULER_NO_TASK; |
395 | } | 395 | } |
396 | s->recv_wakeup_task = GNUNET_SCHEDULER_add_delayed (delta, &client_wake_up, s); | 396 | s->recv_wakeup_task = |
397 | GNUNET_SCHEDULER_add_delayed (delta, &client_wake_up, s); | ||
397 | return CURLPAUSE_ALL; | 398 | return CURLPAUSE_ALL; |
398 | } | 399 | } |
399 | 400 | ||
400 | 401 | ||
401 | if (s->msg_tk == NULL) | 402 | if (s->msg_tk == NULL) |
402 | s->msg_tk = GNUNET_SERVER_mst_create (&client_receive_mst_cb, s); | 403 | s->msg_tk = GNUNET_SERVER_mst_create (&client_receive_mst_cb, s); |
403 | 404 | ||
404 | GNUNET_SERVER_mst_receive (s->msg_tk, s, stream, len, GNUNET_NO, | 405 | GNUNET_SERVER_mst_receive (s->msg_tk, s, stream, len, GNUNET_NO, GNUNET_NO); |
405 | GNUNET_NO); | ||
406 | 406 | ||
407 | return len; | 407 | return len; |
408 | } | 408 | } |
@@ -420,6 +420,7 @@ static size_t | |||
420 | client_send_cb (void *stream, size_t size, size_t nmemb, void *cls) | 420 | client_send_cb (void *stream, size_t size, size_t nmemb, void *cls) |
421 | { | 421 | { |
422 | struct Session *s = cls; | 422 | struct Session *s = cls; |
423 | |||
423 | #if VERBOSE_CLIENT | 424 | #if VERBOSE_CLIENT |
424 | struct Plugin *plugin = s->plugin; | 425 | struct Plugin *plugin = s->plugin; |
425 | #endif | 426 | #endif |
@@ -432,7 +433,8 @@ client_send_cb (void *stream, size_t size, size_t nmemb, void *cls) | |||
432 | { | 433 | { |
433 | #if VERBOSE_CLIENT | 434 | #if VERBOSE_CLIENT |
434 | GNUNET_log_from (GNUNET_ERROR_TYPE_DEBUG, plugin->name, | 435 | GNUNET_log_from (GNUNET_ERROR_TYPE_DEBUG, plugin->name, |
435 | "Client: %X Nothing to send! Suspending PUT handle!\n", s->client_put); | 436 | "Client: %X Nothing to send! Suspending PUT handle!\n", |
437 | s->client_put); | ||
436 | #endif | 438 | #endif |
437 | s->client_put_paused = GNUNET_YES; | 439 | s->client_put_paused = GNUNET_YES; |
438 | return CURL_READFUNC_PAUSE; | 440 | return CURL_READFUNC_PAUSE; |
@@ -469,13 +471,13 @@ client_send_cb (void *stream, size_t size, size_t nmemb, void *cls) | |||
469 | { | 471 | { |
470 | #if VERBOSE_CLIENT | 472 | #if VERBOSE_CLIENT |
471 | GNUNET_log_from (GNUNET_ERROR_TYPE_DEBUG, plugin->name, | 473 | GNUNET_log_from (GNUNET_ERROR_TYPE_DEBUG, plugin->name, |
472 | "Client: %X Message with %u bytes sent, removing message from queue\n", | 474 | "Client: %X Message with %u bytes sent, removing message from queue\n", |
473 | s->client_put, msg->size, msg->pos); | 475 | s->client_put, msg->size, msg->pos); |
474 | #endif | 476 | #endif |
475 | /* Calling transmit continuation */ | 477 | /* Calling transmit continuation */ |
476 | if (NULL != msg->transmit_cont) | 478 | if (NULL != msg->transmit_cont) |
477 | msg->transmit_cont (msg->transmit_cont_cls, &s->target, GNUNET_OK); | 479 | msg->transmit_cont (msg->transmit_cont_cls, &s->target, GNUNET_OK); |
478 | GNUNET_CONTAINER_DLL_remove(s->msg_head, s->msg_tail, msg); | 480 | GNUNET_CONTAINER_DLL_remove (s->msg_head, s->msg_tail, msg); |
479 | GNUNET_free (msg); | 481 | GNUNET_free (msg); |
480 | } | 482 | } |
481 | return bytes_sent; | 483 | return bytes_sent; |
@@ -500,12 +502,11 @@ client_connect (struct Session *s) | |||
500 | plugin->last_tag++; | 502 | plugin->last_tag++; |
501 | /* create url */ | 503 | /* create url */ |
502 | GNUNET_asprintf (&url, "%s%s;%u", | 504 | GNUNET_asprintf (&url, "%s%s;%u", |
503 | http_plugin_address_to_string (plugin, s->addr, s->addrlen), | 505 | http_plugin_address_to_string (plugin, s->addr, s->addrlen), |
504 | GNUNET_h2s_full (&plugin->env->my_identity->hashPubKey),plugin->last_tag); | 506 | GNUNET_h2s_full (&plugin->env->my_identity->hashPubKey), |
507 | plugin->last_tag); | ||
505 | #if 0 | 508 | #if 0 |
506 | GNUNET_log_from (GNUNET_ERROR_TYPE_DEBUG, plugin->name, | 509 | GNUNET_log_from (GNUNET_ERROR_TYPE_DEBUG, plugin->name, "URL `%s'\n", url); |
507 | "URL `%s'\n", | ||
508 | url); | ||
509 | #endif | 510 | #endif |
510 | /* create get connection */ | 511 | /* create get connection */ |
511 | s->client_get = curl_easy_init (); | 512 | s->client_get = curl_easy_init (); |
@@ -592,7 +593,7 @@ client_connect (struct Session *s) | |||
592 | plugin->cur_connections += 2; | 593 | plugin->cur_connections += 2; |
593 | 594 | ||
594 | /* Re-schedule since handles have changed */ | 595 | /* Re-schedule since handles have changed */ |
595 | if (plugin->client_perform_task!= GNUNET_SCHEDULER_NO_TASK) | 596 | if (plugin->client_perform_task != GNUNET_SCHEDULER_NO_TASK) |
596 | { | 597 | { |
597 | GNUNET_SCHEDULER_cancel (plugin->client_perform_task); | 598 | GNUNET_SCHEDULER_cancel (plugin->client_perform_task); |
598 | plugin->client_perform_task = GNUNET_SCHEDULER_NO_TASK; | 599 | plugin->client_perform_task = GNUNET_SCHEDULER_NO_TASK; |