aboutsummaryrefslogtreecommitdiff
path: root/src/ats/ats_api_performance.c
diff options
context:
space:
mode:
authorMatthias Wachs <wachs@net.in.tum.de>2012-11-19 16:30:11 +0000
committerMatthias Wachs <wachs@net.in.tum.de>2012-11-19 16:30:11 +0000
commitf64e7ab9c26ccc0d0d32e7458745f2c70bffd352 (patch)
tree70aaaed20b22fc05e242f7088b73b30cea578612 /src/ats/ats_api_performance.c
parent6c937680c28892c73b6fd380d4ee75e5251274fb (diff)
downloadgnunet-f64e7ab9c26ccc0d0d32e7458745f2c70bffd352.tar.gz
gnunet-f64e7ab9c26ccc0d0d32e7458745f2c70bffd352.zip
changes ... more TBD
Diffstat (limited to 'src/ats/ats_api_performance.c')
-rw-r--r--src/ats/ats_api_performance.c19
1 files changed, 17 insertions, 2 deletions
diff --git a/src/ats/ats_api_performance.c b/src/ats/ats_api_performance.c
index 49e0df595..b86276363 100644
--- a/src/ats/ats_api_performance.c
+++ b/src/ats/ats_api_performance.c
@@ -648,6 +648,8 @@ GNUNET_ATS_performance_list_addresses (struct GNUNET_ATS_PerformanceHandle *hand
648 void *infocb_cls) 648 void *infocb_cls)
649{ 649{
650 struct GNUNET_ATS_AddressListHandle *alh; 650 struct GNUNET_ATS_AddressListHandle *alh;
651 struct PendingMessage *p;
652 struct AddressListRequestMessage *m;
651 653
652 GNUNET_assert (NULL != handle); 654 GNUNET_assert (NULL != handle);
653 655
@@ -666,8 +668,21 @@ GNUNET_ATS_performance_list_addresses (struct GNUNET_ATS_PerformanceHandle *hand
666 668
667 GNUNET_CONTAINER_DLL_insert (handle->addresslist_head, handle->addresslist_tail, alh); 669 GNUNET_CONTAINER_DLL_insert (handle->addresslist_head, handle->addresslist_tail, alh);
668 670
669 /* TODO */ 671 p = GNUNET_malloc (sizeof (struct PendingMessage) +
670 FPRINTF (stderr, "TBD"); 672 sizeof (struct AddressListRequestMessage));
673 p->size = sizeof (struct AddressListRequestMessage);
674 m = (struct AddressListRequestMessage *) &p[1];
675 m->header.type = htons (GNUNET_MESSAGE_TYPE_ATS_ADDRESSLIST_REQUEST);
676 m->header.size = htons (sizeof (struct AddressListRequestMessage));
677 m->all = htonl (all);
678 if (NULL != peer)
679 m->peer = *peer;
680 else
681 {
682 memset (&m->peer, '\0', sizeof (struct GNUNET_PeerIdentity));
683 }
684 GNUNET_CONTAINER_DLL_insert_tail (handle->pending_head, handle->pending_tail, p);
685 do_transmit (handle);
671 686
672 return alh; 687 return alh;
673} 688}