gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[GNUnet-SVN] [gnunet] branch master updated: Reinitialise the (client) s


From: gnunet
Subject: [GNUnet-SVN] [gnunet] branch master updated: Reinitialise the (client) sampler element after querying
Date: Fri, 24 Aug 2018 12:48:59 +0200

This is an automated email from the git hooks/post-receive script.

julius-buenger pushed a commit to branch master
in repository gnunet.

The following commit(s) were added to refs/heads/master by this push:
     new dc86c377a Reinitialise the (client) sampler element after querying
dc86c377a is described below

commit dc86c377a63e79ab2d17ce644ea060d1ce0c6b0c
Author: Julius Bünger <address@hidden>
AuthorDate: Fri Aug 24 12:47:54 2018 +0200

    Reinitialise the (client) sampler element after querying
---
 src/rps/gnunet-service-rps_sampler.c | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/src/rps/gnunet-service-rps_sampler.c 
b/src/rps/gnunet-service-rps_sampler.c
index 4d1ae4650..2974c3cbc 100644
--- a/src/rps/gnunet-service-rps_sampler.c
+++ b/src/rps/gnunet-service-rps_sampler.c
@@ -254,9 +254,10 @@ static uint32_t client_get_index;
  */
 static void
 check_n_peers_ready (void *cls,
-    const struct GNUNET_PeerIdentity *id)
+                     const struct GNUNET_PeerIdentity *id)
 {
   struct RPS_SamplerRequestHandle *req_handle = cls;
+  (void) id;
 
   req_handle->cur_num_peers++;
   LOG (GNUNET_ERROR_TYPE_DEBUG,
@@ -571,8 +572,7 @@ sampler_get_rand_peer (void *cls)
 /**
  * Get one random peer out of the sampled peers.
  *
- * We might want to reinitialise this sampler after giving the
- * corrsponding peer to the client.
+ * This reinitialises the queried sampler element.
  */
 static void
 sampler_mod_get_rand_peer (void *cls)
@@ -635,6 +635,7 @@ sampler_mod_get_rand_peer (void *cls)
   }
 
   s_elem->last_client_request = GNUNET_TIME_absolute_get ();
+  RPS_sampler_elem_reinit (s_elem);
 
   GNUNET_CONTAINER_DLL_remove (gpc->req_handle->gpc_head,
                                gpc->req_handle->gpc_tail,

-- 
To stop receiving notification emails like this one, please contact
address@hidden



reply via email to

[Prev in Thread] Current Thread [Next in Thread]