aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/core/gnunet-service-core.c20
-rw-r--r--src/dv/gnunet-service-dv.c11
-rw-r--r--src/hostlist/hostlist-server.c20
-rw-r--r--src/include/gnunet_peerinfo_service.h4
-rw-r--r--src/peerinfo-tool/gnunet-peerinfo.c5
-rw-r--r--src/peerinfo/peerinfo_api.c44
-rw-r--r--src/peerinfo/peerinfo_api_notify.c2
-rwxr-xr-xsrc/peerinfo/perf_peerinfo_api.c3
-rw-r--r--src/peerinfo/test_peerinfo_api.c9
-rw-r--r--src/topology/gnunet-daemon-topology.c11
-rw-r--r--src/transport/gnunet-service-transport.c23
11 files changed, 119 insertions, 33 deletions
diff --git a/src/core/gnunet-service-core.c b/src/core/gnunet-service-core.c
index 290160414..dd1937f06 100644
--- a/src/core/gnunet-service-core.c
+++ b/src/core/gnunet-service-core.c
@@ -3006,10 +3006,18 @@ handle_client_request_connect (void *cls,
3006static void 3006static void
3007process_hello_retry_send_key (void *cls, 3007process_hello_retry_send_key (void *cls,
3008 const struct GNUNET_PeerIdentity *peer, 3008 const struct GNUNET_PeerIdentity *peer,
3009 const struct GNUNET_HELLO_Message *hello) 3009 const struct GNUNET_HELLO_Message *hello,
3010 const char *err_msg)
3010{ 3011{
3011 struct Neighbour *n = cls; 3012 struct Neighbour *n = cls;
3012 3013
3014 if (err_msg != NULL)
3015 {
3016 GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
3017 _("Error in communication with PEERINFO service\n"));
3018 /* return; */
3019 }
3020
3013 if (peer == NULL) 3021 if (peer == NULL)
3014 { 3022 {
3015#if DEBUG_CORE 3023#if DEBUG_CORE
@@ -3318,11 +3326,19 @@ handle_set_key (struct Neighbour *n,
3318static void 3326static void
3319process_hello_retry_handle_set_key (void *cls, 3327process_hello_retry_handle_set_key (void *cls,
3320 const struct GNUNET_PeerIdentity *peer, 3328 const struct GNUNET_PeerIdentity *peer,
3321 const struct GNUNET_HELLO_Message *hello) 3329 const struct GNUNET_HELLO_Message *hello,
3330 const char *err_msg)
3322{ 3331{
3323 struct Neighbour *n = cls; 3332 struct Neighbour *n = cls;
3324 struct SetKeyMessage *sm = n->skm; 3333 struct SetKeyMessage *sm = n->skm;
3325 3334
3335 if (err_msg != NULL)
3336 {
3337 GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
3338 _("Error in communication with PEERINFO service\n"));
3339 /* return; */
3340 }
3341
3326 if (peer == NULL) 3342 if (peer == NULL)
3327 { 3343 {
3328 n->skm = NULL; 3344 n->skm = NULL;
diff --git a/src/dv/gnunet-service-dv.c b/src/dv/gnunet-service-dv.c
index cd54686f3..223b95fed 100644
--- a/src/dv/gnunet-service-dv.c
+++ b/src/dv/gnunet-service-dv.c
@@ -2806,11 +2806,13 @@ add_all_direct_neighbors (void *cls,
2806 * @param cls closure 2806 * @param cls closure
2807 * @param peer id of the peer, NULL for last call 2807 * @param peer id of the peer, NULL for last call
2808 * @param hello hello message for the peer (can be NULL) 2808 * @param hello hello message for the peer (can be NULL)
2809 * @param err_msg NULL if successful, otherwise contains error message
2809 */ 2810 */
2810static void 2811static void
2811process_peerinfo (void *cls, 2812process_peerinfo (void *cls,
2812 const struct GNUNET_PeerIdentity *peer, 2813 const struct GNUNET_PeerIdentity *peer,
2813 const struct GNUNET_HELLO_Message *hello) 2814 const struct GNUNET_HELLO_Message *hello,
2815 const char *err_msg)
2814{ 2816{
2815 struct PeerIteratorContext *peerinfo_iterator = cls; 2817 struct PeerIteratorContext *peerinfo_iterator = cls;
2816 struct DirectNeighbor *neighbor = peerinfo_iterator->neighbor; 2818 struct DirectNeighbor *neighbor = peerinfo_iterator->neighbor;
@@ -2819,7 +2821,12 @@ process_peerinfo (void *cls,
2819 char *neighbor_pid; 2821 char *neighbor_pid;
2820#endif 2822#endif
2821 int sent; 2823 int sent;
2822 2824 if (err_msg != NULL)
2825 {
2826 GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
2827 _("Error in communication with PEERINFO service\n"));
2828 /* return; */
2829 }
2823 if (peer == NULL) 2830 if (peer == NULL)
2824 { 2831 {
2825 if (distant->pkey == NULL) 2832 if (distant->pkey == NULL)
diff --git a/src/hostlist/hostlist-server.c b/src/hostlist/hostlist-server.c
index 95272a555..4c88ae317 100644
--- a/src/hostlist/hostlist-server.c
+++ b/src/hostlist/hostlist-server.c
@@ -178,13 +178,21 @@ check_has_addr (void *cls,
178static void 178static void
179host_processor (void *cls, 179host_processor (void *cls,
180 const struct GNUNET_PeerIdentity * peer, 180 const struct GNUNET_PeerIdentity * peer,
181 const struct GNUNET_HELLO_Message *hello) 181 const struct GNUNET_HELLO_Message *hello,
182 const char *err_msg)
182{ 183{
183 struct HostSet *results = cls; 184 struct HostSet *results = cls;
184 size_t old; 185 size_t old;
185 size_t s; 186 size_t s;
186 int has_addr; 187 int has_addr;
187 188
189 if (err_msg != NULL)
190 {
191 GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
192 _("Error in communication with PEERINFO service:\n `%s'"), err_msg);
193 return;
194 }
195
188 if (peer == NULL) 196 if (peer == NULL)
189 { 197 {
190 pitr = NULL; 198 pitr = NULL;
@@ -439,17 +447,25 @@ disconnect_handler (void *cls,
439 * @param cls closure (not used) 447 * @param cls closure (not used)
440 * @param peer potential peer to connect to 448 * @param peer potential peer to connect to
441 * @param hello HELLO for this peer (or NULL) 449 * @param hello HELLO for this peer (or NULL)
450 * @param err_msg NULL if successful, otherwise contains error message
442 */ 451 */
443static void 452static void
444process_notify (void *cls, 453process_notify (void *cls,
445 const struct GNUNET_PeerIdentity *peer, 454 const struct GNUNET_PeerIdentity *peer,
446 const struct GNUNET_HELLO_Message *hello) 455 const struct GNUNET_HELLO_Message *hello,
456 const char *err_msg)
447{ 457{
448 struct HostSet *results; 458 struct HostSet *results;
449#if DEBUG_HOSTLIST_SERVER 459#if DEBUG_HOSTLIST_SERVER
450 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 460 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
451 "Peerinfo is notifying us to rebuild our hostlist\n"); 461 "Peerinfo is notifying us to rebuild our hostlist\n");
452#endif 462#endif
463 if (err_msg != NULL)
464 {
465 GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
466 _("Error in communication with PEERINFO service\n"));
467 /* return; */
468 }
453 results = GNUNET_malloc(sizeof(struct HostSet)); 469 results = GNUNET_malloc(sizeof(struct HostSet));
454 GNUNET_assert (peerinfo != NULL); 470 GNUNET_assert (peerinfo != NULL);
455 pitr = GNUNET_PEERINFO_iterate (peerinfo, 471 pitr = GNUNET_PEERINFO_iterate (peerinfo,
diff --git a/src/include/gnunet_peerinfo_service.h b/src/include/gnunet_peerinfo_service.h
index 1c34d83bb..1411168c0 100644
--- a/src/include/gnunet_peerinfo_service.h
+++ b/src/include/gnunet_peerinfo_service.h
@@ -95,11 +95,13 @@ GNUNET_PEERINFO_add_peer (struct GNUNET_PEERINFO_Handle *h,
95 * @param cls closure 95 * @param cls closure
96 * @param peer id of the peer, NULL for last call 96 * @param peer id of the peer, NULL for last call
97 * @param hello hello message for the peer (can be NULL) 97 * @param hello hello message for the peer (can be NULL)
98 * @param error message
98 */ 99 */
99typedef void 100typedef void
100 (*GNUNET_PEERINFO_Processor) (void *cls, 101 (*GNUNET_PEERINFO_Processor) (void *cls,
101 const struct GNUNET_PeerIdentity * peer, 102 const struct GNUNET_PeerIdentity * peer,
102 const struct GNUNET_HELLO_Message * hello); 103 const struct GNUNET_HELLO_Message * hello,
104 const char * err_msg);
103 105
104 106
105/** 107/**
diff --git a/src/peerinfo-tool/gnunet-peerinfo.c b/src/peerinfo-tool/gnunet-peerinfo.c
index 42adcaad8..48cbb6038 100644
--- a/src/peerinfo-tool/gnunet-peerinfo.c
+++ b/src/peerinfo-tool/gnunet-peerinfo.c
@@ -157,14 +157,15 @@ print_address (void *cls,
157static void 157static void
158print_peer_info (void *cls, 158print_peer_info (void *cls,
159 const struct GNUNET_PeerIdentity *peer, 159 const struct GNUNET_PeerIdentity *peer,
160 const struct GNUNET_HELLO_Message *hello) 160 const struct GNUNET_HELLO_Message *hello,
161 const char * err_msg)
161{ 162{
162 struct GNUNET_CRYPTO_HashAsciiEncoded enc; 163 struct GNUNET_CRYPTO_HashAsciiEncoded enc;
163 struct PrintContext *pc; 164 struct PrintContext *pc;
164 165
165 if (peer == NULL) 166 if (peer == NULL)
166 { 167 {
167 fprintf (stderr,_("Error in communication with PEERINFO service\n")); 168 if (err_msg != NULL) fprintf (stderr,_("Error in communication with PEERINFO service\n"));
168 GNUNET_PEERINFO_disconnect (peerinfo); 169 GNUNET_PEERINFO_disconnect (peerinfo);
169 return; 170 return;
170 } 171 }
diff --git a/src/peerinfo/peerinfo_api.c b/src/peerinfo/peerinfo_api.c
index c2e091f00..a3a396d90 100644
--- a/src/peerinfo/peerinfo_api.c
+++ b/src/peerinfo/peerinfo_api.c
@@ -385,15 +385,16 @@ peerinfo_handler (void *cls, const struct GNUNET_MessageHeader *msg)
385 ic->h->in_receive = GNUNET_NO; 385 ic->h->in_receive = GNUNET_NO;
386 if (msg == NULL) 386 if (msg == NULL)
387 { 387 {
388 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 388 char * err_msg;
389 _("Failed to receive response from `%s' service.\n"), 389 GNUNET_asprintf(&err_msg,_("Failed to receive response from `%s' service.\n"),"PEERINFO");
390 "PEERINFO"); 390 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,err_msg);
391 reconnect (ic->h); 391 reconnect (ic->h);
392 trigger_transmit (ic->h); 392 trigger_transmit (ic->h);
393 if (ic->timeout_task != GNUNET_SCHEDULER_NO_TASK) 393 if (ic->timeout_task != GNUNET_SCHEDULER_NO_TASK)
394 GNUNET_SCHEDULER_cancel (ic->timeout_task); 394 GNUNET_SCHEDULER_cancel (ic->timeout_task);
395 if (ic->callback != NULL) 395 if (ic->callback != NULL)
396 ic->callback (ic->callback_cls, NULL, NULL); 396 ic->callback (ic->callback_cls, NULL, NULL, err_msg);
397 GNUNET_free (err_msg);
397 GNUNET_free (ic); 398 GNUNET_free (ic);
398 return; 399 return;
399 } 400 }
@@ -408,7 +409,7 @@ peerinfo_handler (void *cls, const struct GNUNET_MessageHeader *msg)
408 if (ic->timeout_task != GNUNET_SCHEDULER_NO_TASK) 409 if (ic->timeout_task != GNUNET_SCHEDULER_NO_TASK)
409 GNUNET_SCHEDULER_cancel (ic->timeout_task); 410 GNUNET_SCHEDULER_cancel (ic->timeout_task);
410 if (ic->callback != NULL) 411 if (ic->callback != NULL)
411 ic->callback (ic->callback_cls, NULL, NULL); 412 ic->callback (ic->callback_cls, NULL, NULL, NULL);
412 GNUNET_free (ic); 413 GNUNET_free (ic);
413 return; 414 return;
414 } 415 }
@@ -416,13 +417,17 @@ peerinfo_handler (void *cls, const struct GNUNET_MessageHeader *msg)
416 if ((ms < sizeof (struct InfoMessage)) || 417 if ((ms < sizeof (struct InfoMessage)) ||
417 (ntohs (msg->type) != GNUNET_MESSAGE_TYPE_PEERINFO_INFO)) 418 (ntohs (msg->type) != GNUNET_MESSAGE_TYPE_PEERINFO_INFO))
418 { 419 {
420 char * err_msg;
421 GNUNET_asprintf(&err_msg,_("Received invalid message from `%s' service.\n"),"PEERINFO");
422 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,err_msg);
419 GNUNET_break (0); 423 GNUNET_break (0);
420 reconnect (ic->h); 424 reconnect (ic->h);
421 trigger_transmit (ic->h); 425 trigger_transmit (ic->h);
422 if (ic->timeout_task != GNUNET_SCHEDULER_NO_TASK) 426 if (ic->timeout_task != GNUNET_SCHEDULER_NO_TASK)
423 GNUNET_SCHEDULER_cancel (ic->timeout_task); 427 GNUNET_SCHEDULER_cancel (ic->timeout_task);
424 if (ic->callback != NULL) 428 if (ic->callback != NULL)
425 ic->callback (ic->callback_cls, NULL, NULL); 429 ic->callback (ic->callback_cls, NULL, NULL, err_msg);
430 GNUNET_free (err_msg);
426 GNUNET_free (ic); 431 GNUNET_free (ic);
427 return; 432 return;
428 } 433 }
@@ -434,14 +439,17 @@ peerinfo_handler (void *cls, const struct GNUNET_MessageHeader *msg)
434 hello = (const struct GNUNET_HELLO_Message *) &im[1]; 439 hello = (const struct GNUNET_HELLO_Message *) &im[1];
435 if (ms != sizeof (struct InfoMessage) + GNUNET_HELLO_size (hello)) 440 if (ms != sizeof (struct InfoMessage) + GNUNET_HELLO_size (hello))
436 { 441 {
437 GNUNET_break (0); 442 char * err_msg;
443 GNUNET_asprintf(&err_msg,_("Received invalid message from `%s' service.\n"),"PEERINFO");
444 GNUNET_break (0);
438 reconnect (ic->h); 445 reconnect (ic->h);
439 trigger_transmit (ic->h); 446 trigger_transmit (ic->h);
440 if (ic->timeout_task != GNUNET_SCHEDULER_NO_TASK) 447 if (ic->timeout_task != GNUNET_SCHEDULER_NO_TASK)
441 GNUNET_SCHEDULER_cancel (ic->timeout_task); 448 GNUNET_SCHEDULER_cancel (ic->timeout_task);
442 if (ic->callback != NULL) 449 if (ic->callback != NULL)
443 ic->callback (ic->callback_cls, NULL, NULL); 450 ic->callback (ic->callback_cls, NULL, NULL, err_msg);
444 GNUNET_free (ic); 451 GNUNET_free (ic);
452 GNUNET_free (err_msg);
445 return; 453 return;
446 } 454 }
447 } 455 }
@@ -455,7 +463,7 @@ peerinfo_handler (void *cls, const struct GNUNET_MessageHeader *msg)
455#endif 463#endif
456 ic->h->in_receive = GNUNET_YES; 464 ic->h->in_receive = GNUNET_YES;
457 if (ic->callback != NULL) 465 if (ic->callback != NULL)
458 ic->callback (ic->callback_cls, &im->peer, hello); 466 ic->callback (ic->callback_cls, &im->peer, hello, NULL);
459 GNUNET_CLIENT_receive (ic->h->client, 467 GNUNET_CLIENT_receive (ic->h->client,
460 &peerinfo_handler, 468 &peerinfo_handler,
461 ic, 469 ic,
@@ -478,10 +486,9 @@ iterator_start_receive (void *cls,
478 486
479 if (GNUNET_OK != transmit_success) 487 if (GNUNET_OK != transmit_success)
480 { 488 {
481 GNUNET_log (GNUNET_ERROR_TYPE_WARNING, 489 char * err_msg;
482 _("Failed to transmit iteration request to `%s' service (%d).\n"), 490 GNUNET_asprintf(&err_msg,_("Failed to transmit iteration request to `%s' service (%d).\n"),"PEERINFO",transmit_success);
483 "PEERINFO", 491 GNUNET_log (GNUNET_ERROR_TYPE_WARNING,err_msg);
484 transmit_success);
485 if (ic->timeout_task != GNUNET_SCHEDULER_NO_TASK) 492 if (ic->timeout_task != GNUNET_SCHEDULER_NO_TASK)
486 { 493 {
487 GNUNET_SCHEDULER_cancel (ic->timeout_task); 494 GNUNET_SCHEDULER_cancel (ic->timeout_task);
@@ -490,7 +497,8 @@ iterator_start_receive (void *cls,
490 reconnect (ic->h); 497 reconnect (ic->h);
491 trigger_transmit (ic->h); 498 trigger_transmit (ic->h);
492 if (ic->callback != NULL) 499 if (ic->callback != NULL)
493 ic->callback (ic->callback_cls, NULL, NULL); 500 ic->callback (ic->callback_cls, NULL, NULL, err_msg);
501 GNUNET_free (err_msg);
494 GNUNET_free (ic); 502 GNUNET_free (ic);
495 return; 503 return;
496 } 504 }
@@ -520,19 +528,21 @@ signal_timeout (void *cls,
520 const struct GNUNET_SCHEDULER_TaskContext *tc) 528 const struct GNUNET_SCHEDULER_TaskContext *tc)
521{ 529{
522 struct GNUNET_PEERINFO_IteratorContext *ic = cls; 530 struct GNUNET_PEERINFO_IteratorContext *ic = cls;
531 char * err_msg;
523 532
524 GNUNET_log (GNUNET_ERROR_TYPE_WARNING | GNUNET_ERROR_TYPE_BULK, 533 GNUNET_asprintf(&err_msg,_("Timeout transmitting iteration request to `%s' service.\n"),
525 _("Timeout transmitting iteration request to `%s' service.\n"),
526 "PEERINFO"); 534 "PEERINFO");
535 GNUNET_log (GNUNET_ERROR_TYPE_WARNING | GNUNET_ERROR_TYPE_BULK,err_msg);
527 ic->timeout_task = GNUNET_SCHEDULER_NO_TASK; 536 ic->timeout_task = GNUNET_SCHEDULER_NO_TASK;
528 if (! ic->in_receive) 537 if (! ic->in_receive)
529 GNUNET_CONTAINER_DLL_remove (ic->h->tq_head, 538 GNUNET_CONTAINER_DLL_remove (ic->h->tq_head,
530 ic->h->tq_tail, 539 ic->h->tq_tail,
531 ic->tqe); 540 ic->tqe);
532 reconnect (ic->h); 541 reconnect (ic->h);
533 ic->callback (ic->callback_cls, NULL, NULL); 542 ic->callback (ic->callback_cls, NULL, NULL,err_msg);
534 ic->callback = NULL; 543 ic->callback = NULL;
535 GNUNET_free_non_null (ic->tqe); 544 GNUNET_free_non_null (ic->tqe);
545 GNUNET_free (err_msg);
536 GNUNET_free (ic); 546 GNUNET_free (ic);
537} 547}
538 548
diff --git a/src/peerinfo/peerinfo_api_notify.c b/src/peerinfo/peerinfo_api_notify.c
index 25f2b9d5e..ab0d13f66 100644
--- a/src/peerinfo/peerinfo_api_notify.c
+++ b/src/peerinfo/peerinfo_api_notify.c
@@ -138,7 +138,7 @@ process_notification (void *cls,
138 "Received information about peer `%s' from peerinfo database\n", 138 "Received information about peer `%s' from peerinfo database\n",
139 GNUNET_i2s (&im->peer)); 139 GNUNET_i2s (&im->peer));
140#endif 140#endif
141 nc->callback (nc->callback_cls, &im->peer, hello); 141 nc->callback (nc->callback_cls, &im->peer, hello, NULL);
142 receive_notifications (nc); 142 receive_notifications (nc);
143} 143}
144 144
diff --git a/src/peerinfo/perf_peerinfo_api.c b/src/peerinfo/perf_peerinfo_api.c
index 1de0f4615..4cae7ab60 100755
--- a/src/peerinfo/perf_peerinfo_api.c
+++ b/src/peerinfo/perf_peerinfo_api.c
@@ -107,7 +107,8 @@ add_peer (size_t i)
107static void 107static void
108process (void *cls, 108process (void *cls,
109 const struct GNUNET_PeerIdentity *peer, 109 const struct GNUNET_PeerIdentity *peer,
110 const struct GNUNET_HELLO_Message *hello) 110 const struct GNUNET_HELLO_Message *hello,
111 const char * err_msg)
111{ 112{
112 if (peer == NULL) 113 if (peer == NULL)
113 { 114 {
diff --git a/src/peerinfo/test_peerinfo_api.c b/src/peerinfo/test_peerinfo_api.c
index 4030820d7..460a3764d 100644
--- a/src/peerinfo/test_peerinfo_api.c
+++ b/src/peerinfo/test_peerinfo_api.c
@@ -100,11 +100,18 @@ add_peer ()
100static void 100static void
101process (void *cls, 101process (void *cls,
102 const struct GNUNET_PeerIdentity *peer, 102 const struct GNUNET_PeerIdentity *peer,
103 const struct GNUNET_HELLO_Message *hello) 103 const struct GNUNET_HELLO_Message *hello,
104 const char * err_msg)
104{ 105{
105 int *ok = cls; 106 int *ok = cls;
106 unsigned int agc; 107 unsigned int agc;
107 108
109 if (err_msg != NULL)
110 {
111 GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
112 _("Error in communication with PEERINFO service\n"));
113 }
114
108 if (peer == NULL) 115 if (peer == NULL)
109 { 116 {
110 ic = NULL; 117 ic = NULL;
diff --git a/src/topology/gnunet-daemon-topology.c b/src/topology/gnunet-daemon-topology.c
index 4bbe4e19a..7cab16d15 100644
--- a/src/topology/gnunet-daemon-topology.c
+++ b/src/topology/gnunet-daemon-topology.c
@@ -924,14 +924,23 @@ consider_for_advertising (const struct GNUNET_HELLO_Message *hello)
924 * @param cls closure (not used) 924 * @param cls closure (not used)
925 * @param peer potential peer to connect to 925 * @param peer potential peer to connect to
926 * @param hello HELLO for this peer (or NULL) 926 * @param hello HELLO for this peer (or NULL)
927 * @param err_msg NULL if successful, otherwise contains error message
927 */ 928 */
928static void 929static void
929process_peer (void *cls, 930process_peer (void *cls,
930 const struct GNUNET_PeerIdentity *peer, 931 const struct GNUNET_PeerIdentity *peer,
931 const struct GNUNET_HELLO_Message *hello) 932 const struct GNUNET_HELLO_Message *hello,
933 const char *err_msg)
932{ 934{
933 struct Peer *pos; 935 struct Peer *pos;
934 936
937 if (err_msg != NULL)
938 {
939 GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
940 _("Error in communication with PEERINFO service\n"));
941 /* return; */
942 }
943
935 GNUNET_assert (peer != NULL); 944 GNUNET_assert (peer != NULL);
936 if (0 == memcmp (&my_identity, 945 if (0 == memcmp (&my_identity,
937 peer, sizeof (struct GNUNET_PeerIdentity))) 946 peer, sizeof (struct GNUNET_PeerIdentity)))
diff --git a/src/transport/gnunet-service-transport.c b/src/transport/gnunet-service-transport.c
index b2e0c2ee4..43001dbc7 100644
--- a/src/transport/gnunet-service-transport.c
+++ b/src/transport/gnunet-service-transport.c
@@ -2710,15 +2710,23 @@ add_to_foreign_address_list (void *cls,
2710 * @param cls closure ('struct NeighbourList*') 2710 * @param cls closure ('struct NeighbourList*')
2711 * @param peer id of the peer, NULL for last call 2711 * @param peer id of the peer, NULL for last call
2712 * @param h hello message for the peer (can be NULL) 2712 * @param h hello message for the peer (can be NULL)
2713 * @param err_msg NULL if successful, otherwise contains error message
2713 */ 2714 */
2714static void 2715static void
2715add_hello_for_peer (void *cls, 2716add_hello_for_peer (void *cls,
2716 const struct GNUNET_PeerIdentity *peer, 2717 const struct GNUNET_PeerIdentity *peer,
2717 const struct GNUNET_HELLO_Message *h) 2718 const struct GNUNET_HELLO_Message *h,
2719 const char *err_msg)
2718{ 2720{
2719 struct NeighbourList *n = cls; 2721 struct NeighbourList *n = cls;
2720 2722
2721 if (peer == NULL) 2723 if (err_msg != NULL)
2724 {
2725 GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
2726 _("Error in communication with PEERINFO service\n"));
2727 /* return; */
2728 }
2729 if ((peer == NULL))
2722 { 2730 {
2723 GNUNET_STATISTICS_update (stats, 2731 GNUNET_STATISTICS_update (stats,
2724 gettext_noop ("# outstanding peerinfo iterate requests"), 2732 gettext_noop ("# outstanding peerinfo iterate requests"),
@@ -4029,11 +4037,13 @@ run_validation (void *cls,
4029 * @param cls closure 4037 * @param cls closure
4030 * @param peer id of the peer, NULL for last call 4038 * @param peer id of the peer, NULL for last call
4031 * @param h hello message for the peer (can be NULL) 4039 * @param h hello message for the peer (can be NULL)
4040 * @param err_msg NULL if successful, otherwise contains error message
4032 */ 4041 */
4033static void 4042static void
4034check_hello_validated (void *cls, 4043check_hello_validated (void *cls,
4035 const struct GNUNET_PeerIdentity *peer, 4044 const struct GNUNET_PeerIdentity *peer,
4036 const struct GNUNET_HELLO_Message *h) 4045 const struct GNUNET_HELLO_Message *h,
4046 const char *err_msg)
4037{ 4047{
4038 struct CheckHelloValidatedContext *chvc = cls; 4048 struct CheckHelloValidatedContext *chvc = cls;
4039 struct GNUNET_HELLO_Message *plain_hello; 4049 struct GNUNET_HELLO_Message *plain_hello;
@@ -4041,6 +4051,13 @@ check_hello_validated (void *cls,
4041 struct GNUNET_PeerIdentity target; 4051 struct GNUNET_PeerIdentity target;
4042 struct NeighbourList *n; 4052 struct NeighbourList *n;
4043 4053
4054 if (err_msg != NULL)
4055 {
4056 GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
4057 _("Error in communication with PEERINFO service\n"));
4058 /* return; */
4059 }
4060
4044 if (peer == NULL) 4061 if (peer == NULL)
4045 { 4062 {
4046 GNUNET_STATISTICS_update (stats, 4063 GNUNET_STATISTICS_update (stats,