aboutsummaryrefslogtreecommitdiff
path: root/src/fs/gnunet-service-fs_pr.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2015-10-25 23:47:39 +0000
committerChristian Grothoff <christian@grothoff.org>2015-10-25 23:47:39 +0000
commit7c55f94e78c72d3b78a5c6007e3658ae30e1f64b (patch)
tree77cb53d80cbb79053a68c71a270586e6e0dcb1ef /src/fs/gnunet-service-fs_pr.c
parent124f3e77a5e022f5f7ab49df49023d0080bcbbb4 (diff)
downloadgnunet-7c55f94e78c72d3b78a5c6007e3658ae30e1f64b.tar.gz
gnunet-7c55f94e78c72d3b78a5c6007e3658ae30e1f64b.zip
-use hash in prd query to reduce memory consumption of CP request_map
Diffstat (limited to 'src/fs/gnunet-service-fs_pr.c')
-rw-r--r--src/fs/gnunet-service-fs_pr.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/src/fs/gnunet-service-fs_pr.c b/src/fs/gnunet-service-fs_pr.c
index b507992b4..21b00e80e 100644
--- a/src/fs/gnunet-service-fs_pr.c
+++ b/src/fs/gnunet-service-fs_pr.c
@@ -289,7 +289,8 @@ GSF_pending_request_create_ (enum GSF_PendingRequestOptions options,
289 enum GNUNET_BLOCK_Type type, 289 enum GNUNET_BLOCK_Type type,
290 const struct GNUNET_HashCode *query, 290 const struct GNUNET_HashCode *query,
291 const struct GNUNET_PeerIdentity *target, 291 const struct GNUNET_PeerIdentity *target,
292 const char *bf_data, size_t bf_size, 292 const char *bf_data,
293 size_t bf_size,
293 uint32_t mingle, 294 uint32_t mingle,
294 uint32_t anonymity_level, 295 uint32_t anonymity_level,
295 uint32_t priority, 296 uint32_t priority,
@@ -325,7 +326,9 @@ GSF_pending_request_create_ (enum GSF_PendingRequestOptions options,
325 if (NULL != target) 326 if (NULL != target)
326 { 327 {
327 pr->public_data.target = (struct GNUNET_PeerIdentity *) eptr; 328 pr->public_data.target = (struct GNUNET_PeerIdentity *) eptr;
328 memcpy (eptr, target, sizeof (struct GNUNET_PeerIdentity)); 329 memcpy (eptr,
330 target,
331 sizeof (struct GNUNET_PeerIdentity));
329 } 332 }
330 pr->public_data.anonymity_level = anonymity_level; 333 pr->public_data.anonymity_level = anonymity_level;
331 pr->public_data.priority = priority; 334 pr->public_data.priority = priority;
@@ -397,7 +400,9 @@ GSF_pending_request_create_ (enum GSF_PendingRequestOptions options,
397 UINT32_MAX, 400 UINT32_MAX,
398 GNUNET_TIME_UNIT_FOREVER_ABS, 401 GNUNET_TIME_UNIT_FOREVER_ABS,
399 GNUNET_TIME_UNIT_FOREVER_ABS, 402 GNUNET_TIME_UNIT_FOREVER_ABS,
400 GNUNET_BLOCK_TYPE_ANY, NULL, 0); 403 GNUNET_BLOCK_TYPE_ANY,
404 NULL,
405 0);
401 GSF_pending_request_cancel_ (dpr, 406 GSF_pending_request_cancel_ (dpr,
402 GNUNET_YES); 407 GNUNET_YES);
403 } 408 }