diff options
author | Christian Grothoff <christian@grothoff.org> | 2011-04-21 13:29:22 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2011-04-21 13:29:22 +0000 |
commit | ef98e4c68e05e88ced677d66b9e5b57a382df70d (patch) | |
tree | 64f88544acb7180ba2ca639050059bbb01252e65 /src/fs/gnunet-service-fs_cp.c | |
parent | 8b23412a0e353778e83b370260e40d63a18c3927 (diff) | |
download | gnunet-ef98e4c68e05e88ced677d66b9e5b57a382df70d.tar.gz gnunet-ef98e4c68e05e88ced677d66b9e5b57a382df70d.zip |
fix
Diffstat (limited to 'src/fs/gnunet-service-fs_cp.c')
-rw-r--r-- | src/fs/gnunet-service-fs_cp.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/fs/gnunet-service-fs_cp.c b/src/fs/gnunet-service-fs_cp.c index 92461e477..5aba83298 100644 --- a/src/fs/gnunet-service-fs_cp.c +++ b/src/fs/gnunet-service-fs_cp.c | |||
@@ -616,6 +616,7 @@ copy_reply (void *cls, | |||
616 | * | 616 | * |
617 | * @param cls 'struct GSF_ConnectedPeer' of the peer that would | 617 | * @param cls 'struct GSF_ConnectedPeer' of the peer that would |
618 | * have liked an answer to the request | 618 | * have liked an answer to the request |
619 | * @param eval evaluation of the result | ||
619 | * @param pr handle to the original pending request | 620 | * @param pr handle to the original pending request |
620 | * @param expiration when does 'data' expire? | 621 | * @param expiration when does 'data' expire? |
621 | * @param type type of the block | 622 | * @param type type of the block |
@@ -624,6 +625,7 @@ copy_reply (void *cls, | |||
624 | */ | 625 | */ |
625 | static void | 626 | static void |
626 | handle_p2p_reply (void *cls, | 627 | handle_p2p_reply (void *cls, |
628 | enum GNUNET_BLOCK_EvaluationResult eval, | ||
627 | struct GSF_PendingRequest *pr, | 629 | struct GSF_PendingRequest *pr, |
628 | struct GNUNET_TIME_Absolute expiration, | 630 | struct GNUNET_TIME_Absolute expiration, |
629 | enum GNUNET_BLOCK_Type type, | 631 | enum GNUNET_BLOCK_Type type, |
@@ -683,6 +685,17 @@ handle_p2p_reply (void *cls, | |||
683 | msize, | 685 | msize, |
684 | ©_reply, | 686 | ©_reply, |
685 | pm); | 687 | pm); |
688 | if (eval != GNUNET_BLOCK_EVALUATION_OK_LAST) | ||
689 | return; | ||
690 | GNUNET_STATISTICS_update (GSF_stats, | ||
691 | gettext_noop ("# P2P searches active"), | ||
692 | -1, | ||
693 | GNUNET_NO); | ||
694 | GNUNET_break (GNUNET_OK == | ||
695 | GNUNET_CONTAINER_multihashmap_remove (cp->request_map, | ||
696 | &prd->query, | ||
697 | pr)); | ||
698 | GSF_pending_request_cancel_ (pr); | ||
686 | } | 699 | } |
687 | 700 | ||
688 | 701 | ||