From 26542dad2ef4741edd18e7a2fb1f0745d8189738 Mon Sep 17 00:00:00 2001 From: Supriti Singh Date: Tue, 19 Aug 2014 18:34:58 +0000 Subject: Fixing warning --- src/dht/gnunet-service-xdht_neighbours.h | 26 ++++++++++++++++++++++++++ src/dht/gnunet_dht_profiler.c | 2 +- 2 files changed, 27 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/dht/gnunet-service-xdht_neighbours.h b/src/dht/gnunet-service-xdht_neighbours.h index e1fae570d..57ed68434 100644 --- a/src/dht/gnunet-service-xdht_neighbours.h +++ b/src/dht/gnunet-service-xdht_neighbours.h @@ -74,6 +74,32 @@ GDS_NEIGHBOURS_handle_get(const struct GNUNET_HashCode *key, enum GNUNET_DHT_RouteOption options, uint32_t desired_replication_level); +/** + * Send the get result to requesting client. + * @param key Key of the requested data. + * @param type Block type + * @param target_peer Next peer to forward the message to. + * @param source_peer Peer which has the data for the key. + * @param put_path_length Number of peers in @a put_path + * @param put_path Path taken to put the data at its stored location. + * @param get_path_length Number of peers in @a get_path + * @param get_path Path taken to reach to the location of the key. + * @param expiration When will this result expire? + * @param data Payload to store + * @param data_size Size of the @a data + */ +void +GDS_NEIGHBOURS_send_get_result (const struct GNUNET_HashCode *key, + enum GNUNET_BLOCK_Type type, + const struct GNUNET_PeerIdentity *target_peer, + const struct GNUNET_PeerIdentity *source_peer, + unsigned int put_path_length, + const struct GNUNET_PeerIdentity *put_path, + unsigned int get_path_length, + const struct GNUNET_PeerIdentity *get_path, + struct GNUNET_TIME_Absolute expiration, + const void *data, size_t data_size); + /** * Construct a trail teardown message and forward it to target friend. * @param trail_id Unique identifier of the trail. diff --git a/src/dht/gnunet_dht_profiler.c b/src/dht/gnunet_dht_profiler.c index 31671545d..9c0693e43 100644 --- a/src/dht/gnunet_dht_profiler.c +++ b/src/dht/gnunet_dht_profiler.c @@ -543,7 +543,7 @@ get_iter (void *cls, if (n_active == n_gets_fail + n_gets_ok) { average_put_path_length = (double)total_put_path_length/(double)n_active; - average_get_path_length = (double)total_get_path_length/(double)n_active; + average_get_path_length = (double)total_get_path_length/(double )n_active; summarize (); } } -- cgit v1.2.3