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_udp.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_udp.c')
-rw-r--r-- | src/transport/plugin_transport_udp.c | 16 |
1 files changed, 6 insertions, 10 deletions
diff --git a/src/transport/plugin_transport_udp.c b/src/transport/plugin_transport_udp.c index 885a26b19..228c60d33 100644 --- a/src/transport/plugin_transport_udp.c +++ b/src/transport/plugin_transport_udp.c | |||
@@ -1893,17 +1893,13 @@ process_inbound_tokenized_messages (void *cls, void *client, | |||
1893 | { | 1893 | { |
1894 | struct Plugin *plugin = cls; | 1894 | struct Plugin *plugin = cls; |
1895 | struct SourceInformation *si = client; | 1895 | struct SourceInformation *si = client; |
1896 | struct GNUNET_ATS_Information ats[2]; | ||
1897 | struct GNUNET_TIME_Relative delay; | 1896 | struct GNUNET_TIME_Relative delay; |
1898 | 1897 | ||
1899 | GNUNET_assert (si->session != NULL); | 1898 | GNUNET_assert (si->session != NULL); |
1900 | if (GNUNET_YES == si->session->in_destroy) | 1899 | if (GNUNET_YES == si->session->in_destroy) |
1901 | return GNUNET_OK; | 1900 | return GNUNET_OK; |
1902 | /* setup ATS */ | 1901 | /* setup ATS */ |
1903 | ats[0].type = htonl (GNUNET_ATS_QUALITY_NET_DISTANCE); | 1902 | GNUNET_break (ntohl(si->session->ats.value) != GNUNET_ATS_NET_UNSPECIFIED); |
1904 | ats[0].value = htonl (1); | ||
1905 | ats[1] = si->session->ats; | ||
1906 | GNUNET_break (ntohl(ats[1].value) != GNUNET_ATS_NET_UNSPECIFIED); | ||
1907 | delay = plugin->env->receive (plugin->env->cls, | 1903 | delay = plugin->env->receive (plugin->env->cls, |
1908 | &si->sender, | 1904 | &si->sender, |
1909 | hdr, | 1905 | hdr, |
@@ -1912,11 +1908,11 @@ process_inbound_tokenized_messages (void *cls, void *client, | |||
1912 | si->args); | 1908 | si->args); |
1913 | 1909 | ||
1914 | plugin->env->update_address_metrics (plugin->env->cls, | 1910 | plugin->env->update_address_metrics (plugin->env->cls, |
1915 | &si->sender, | 1911 | &si->sender, |
1916 | si->arg, | 1912 | si->arg, |
1917 | si->args, | 1913 | si->args, |
1918 | si->session, | 1914 | si->session, |
1919 | (struct GNUNET_ATS_Information *) &ats, 2); | 1915 | &si->session->ats, 1); |
1920 | 1916 | ||
1921 | si->session->flow_delay_for_other_peer = delay; | 1917 | si->session->flow_delay_for_other_peer = delay; |
1922 | reschedule_session_timeout(si->session); | 1918 | reschedule_session_timeout(si->session); |