diff options
-rw-r--r-- | src/dv/plugin_transport_dv.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/src/dv/plugin_transport_dv.c b/src/dv/plugin_transport_dv.c index 84afb8344..f094075e8 100644 --- a/src/dv/plugin_transport_dv.c +++ b/src/dv/plugin_transport_dv.c | |||
@@ -172,7 +172,16 @@ struct Plugin | |||
172 | static void | 172 | static void |
173 | notify_distance_change (struct Session *session) | 173 | notify_distance_change (struct Session *session) |
174 | { | 174 | { |
175 | GNUNET_break (0); // FIXME: need extended plugin API! | 175 | struct Plugin *plugin = session->plugin; |
176 | struct GNUNET_ATS_Information ats; | ||
177 | |||
178 | ats.type = htonl ((uint32_t) GNUNET_ATS_QUALITY_NET_DISTANCE); | ||
179 | ats.value = htonl (session->distance); | ||
180 | plugin->env->update_address_metrics (plugin->env->cls, | ||
181 | &session->sender, | ||
182 | "", 0, | ||
183 | session, | ||
184 | &ats, 1); | ||
176 | } | 185 | } |
177 | 186 | ||
178 | 187 | ||