aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorFlorian Dold <florian.dold@gmail.com>2017-03-01 00:03:51 +0100
committerFlorian Dold <florian.dold@gmail.com>2017-03-01 00:03:51 +0100
commit2f3ffc2b053725a26be07763b02091439ae41005 (patch)
treeb63090e4d7267a9c4f7d8c47f324964f0fff8f4e /src
parent50034dd9abff47b5e81a5d91128fd3cb6ae906d5 (diff)
downloadgnunet-2f3ffc2b053725a26be07763b02091439ae41005.tar.gz
gnunet-2f3ffc2b053725a26be07763b02091439ae41005.zip
set: log set difference estimate
Diffstat (limited to 'src')
-rw-r--r--src/set/gnunet-service-set_union.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/set/gnunet-service-set_union.c b/src/set/gnunet-service-set_union.c
index f46713c31..9ca9961ef 100644
--- a/src/set/gnunet-service-set_union.c
+++ b/src/set/gnunet-service-set_union.c
@@ -877,6 +877,8 @@ handle_p2p_strata_estimator (void *cls,
877 if (diff > 200) 877 if (diff > 200)
878 diff = diff * 3 / 2; 878 diff = diff * 3 / 2;
879 879
880
881
880 strata_estimator_destroy (remote_se); 882 strata_estimator_destroy (remote_se);
881 strata_estimator_destroy (op->state->se); 883 strata_estimator_destroy (op->state->se);
882 op->state->se = NULL; 884 op->state->se = NULL;
@@ -885,6 +887,17 @@ handle_p2p_strata_estimator (void *cls,
885 diff, 887 diff,
886 1<<get_order_from_difference (diff)); 888 1<<get_order_from_difference (diff));
887 889
890 {
891 char *set_debug;
892 set_debug = getenv ("GNUNET_SET_BENCHMARK");
893 if ( (NULL != set_debug) && (0 == strcmp (set_debug, "1")) )
894 {
895 FILE *f = fopen ("set.log", "a");
896 fprintf (f, "%llu", (unsigned long long) diff);
897 fclose (f);
898 }
899 }
900
888 if ((GNUNET_YES == op->spec->byzantine) && (other_size < op->spec->byzantine_lower_bound)) 901 if ((GNUNET_YES == op->spec->byzantine) && (other_size < op->spec->byzantine_lower_bound))
889 { 902 {
890 GNUNET_break (0); 903 GNUNET_break (0);