diff options
author | Christian Grothoff <christian@grothoff.org> | 2013-03-30 11:59:49 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2013-03-30 11:59:49 +0000 |
commit | afef053a2ee08002fe50f3e1842e5c8153e6c507 (patch) | |
tree | 8ffc70786908ded09ee74007df75fe33f77d4b72 /src/transport/plugin_transport_http_client.c | |
parent | 4eb0a75f98349e55a405212404b258a987fb6145 (diff) | |
download | gnunet-afef053a2ee08002fe50f3e1842e5c8153e6c507.tar.gz gnunet-afef053a2ee08002fe50f3e1842e5c8153e6c507.zip |
-no longer pass distance information from non-DV plugins
Diffstat (limited to 'src/transport/plugin_transport_http_client.c')
-rw-r--r-- | src/transport/plugin_transport_http_client.c | 18 |
1 files changed, 8 insertions, 10 deletions
diff --git a/src/transport/plugin_transport_http_client.c b/src/transport/plugin_transport_http_client.c index 062941751..00b704a27 100644 --- a/src/transport/plugin_transport_http_client.c +++ b/src/transport/plugin_transport_http_client.c | |||
@@ -903,7 +903,7 @@ client_receive_mst_cb (void *cls, void *client, | |||
903 | struct Session *s = cls; | 903 | struct Session *s = cls; |
904 | struct HTTP_Client_Plugin *plugin; | 904 | struct HTTP_Client_Plugin *plugin; |
905 | struct GNUNET_TIME_Relative delay; | 905 | struct GNUNET_TIME_Relative delay; |
906 | struct GNUNET_ATS_Information atsi[2]; | 906 | struct GNUNET_ATS_Information atsi; |
907 | char *stat_txt; | 907 | char *stat_txt; |
908 | if (GNUNET_YES != client_exist_session(p, s)) | 908 | if (GNUNET_YES != client_exist_session(p, s)) |
909 | { | 909 | { |
@@ -912,21 +912,19 @@ client_receive_mst_cb (void *cls, void *client, | |||
912 | } | 912 | } |
913 | plugin = s->plugin; | 913 | plugin = s->plugin; |
914 | 914 | ||
915 | atsi[0].type = htonl (GNUNET_ATS_QUALITY_NET_DISTANCE); | 915 | atsi.type = htonl (GNUNET_ATS_NETWORK_TYPE); |
916 | atsi[0].value = htonl (1); | 916 | atsi.value = s->ats_address_network_type; |
917 | atsi[1].type = htonl (GNUNET_ATS_NETWORK_TYPE); | ||
918 | atsi[1].value = s->ats_address_network_type; | ||
919 | GNUNET_break (s->ats_address_network_type != ntohl (GNUNET_ATS_NET_UNSPECIFIED)); | 917 | GNUNET_break (s->ats_address_network_type != ntohl (GNUNET_ATS_NET_UNSPECIFIED)); |
920 | 918 | ||
921 | delay = s->plugin->env->receive (plugin->env->cls, &s->target, message, | 919 | delay = s->plugin->env->receive (plugin->env->cls, &s->target, message, |
922 | s, s->addr, s->addrlen); | 920 | s, s->addr, s->addrlen); |
923 | 921 | ||
924 | plugin->env->update_address_metrics (plugin->env->cls, | 922 | plugin->env->update_address_metrics (plugin->env->cls, |
925 | &s->target, | 923 | &s->target, |
926 | s->addr, | 924 | s->addr, |
927 | s->addrlen, | 925 | s->addrlen, |
928 | s, | 926 | s, |
929 | (struct GNUNET_ATS_Information *) &atsi, 2); | 927 | &atsi, 1); |
930 | 928 | ||
931 | GNUNET_asprintf (&stat_txt, "# bytes received via %s_client", plugin->protocol); | 929 | GNUNET_asprintf (&stat_txt, "# bytes received via %s_client", plugin->protocol); |
932 | GNUNET_STATISTICS_update (plugin->env->stats, | 930 | GNUNET_STATISTICS_update (plugin->env->stats, |