diff options
author | Philipp Tölke <toelke@in.tum.de> | 2011-06-15 07:15:37 +0000 |
---|---|---|
committer | Philipp Tölke <toelke@in.tum.de> | 2011-06-15 07:15:37 +0000 |
commit | cf8314b252ee3e439422b8dd372660d073db5562 (patch) | |
tree | 040dec9ed433807ba17f869234f8cabac533b914 /src/vpn/gnunet-daemon-vpn.c | |
parent | 90926706fbdbd6f233175ad71fb0b537e64fdf4b (diff) | |
download | gnunet-cf8314b252ee3e439422b8dd372660d073db5562.tar.gz gnunet-cf8314b252ee3e439422b8dd372660d073db5562.zip |
update the cost later
Diffstat (limited to 'src/vpn/gnunet-daemon-vpn.c')
-rw-r--r-- | src/vpn/gnunet-daemon-vpn.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/vpn/gnunet-daemon-vpn.c b/src/vpn/gnunet-daemon-vpn.c index 34a480a3e..49a33a7bb 100644 --- a/src/vpn/gnunet-daemon-vpn.c +++ b/src/vpn/gnunet-daemon-vpn.c | |||
@@ -357,9 +357,6 @@ process_answer(void* cls, const struct GNUNET_SCHEDULER_TaskContext* tc) { | |||
357 | } | 357 | } |
358 | 358 | ||
359 | struct map_entry* map_entry = GNUNET_CONTAINER_multihashmap_get(hashmap, &key); | 359 | struct map_entry* map_entry = GNUNET_CONTAINER_multihashmap_get(hashmap, &key); |
360 | GNUNET_CONTAINER_heap_update_cost (heap, map_entry->heap_node, | ||
361 | GNUNET_TIME_absolute_get ().abs_value); | ||
362 | |||
363 | uint16_t offset = ntohs(pkt->addroffset); | 360 | uint16_t offset = ntohs(pkt->addroffset); |
364 | 361 | ||
365 | if (map_entry == NULL) | 362 | if (map_entry == NULL) |
@@ -368,6 +365,10 @@ process_answer(void* cls, const struct GNUNET_SCHEDULER_TaskContext* tc) { | |||
368 | return; | 365 | return; |
369 | } | 366 | } |
370 | 367 | ||
368 | GNUNET_CONTAINER_heap_update_cost (heap, map_entry->heap_node, | ||
369 | GNUNET_TIME_absolute_get ().abs_value); | ||
370 | |||
371 | |||
371 | unsigned short namelen = htons(map_entry->namelen); | 372 | unsigned short namelen = htons(map_entry->namelen); |
372 | char* name = (char*)(map_entry + 1); | 373 | char* name = (char*)(map_entry + 1); |
373 | 374 | ||