(no commit message)
[oweals/gnunet.git] / src / transport / gnunet-service-transport.c
index 8f830bd9c6dafca88d9b38babfe8dc300db336af..dc86a69e649c0a98ed5adf697ff4358da2412705 100644 (file)
@@ -228,6 +228,7 @@ GST_receive_callback (void *cls, const struct GNUNET_PeerIdentity *peer,
                         gettext_noop
                         ("# bytes total received"),
                             ntohs (message->size), GNUNET_NO);
+  GST_neighbours_notify_data_recv (peer, &address, session, message);
 
   switch (type)
   {
@@ -275,7 +276,7 @@ GST_receive_callback (void *cls, const struct GNUNET_PeerIdentity *peer,
                               gettext_noop
                               ("# bytes payload received"),
                               ntohs (message->size), GNUNET_NO);
-    GST_neighbours_notify_payload (peer, &address, session, message);
+    GST_neighbours_notify_payload_recv (peer, &address, session, message);
     ret = process_payload (peer, &address, session, message);
     break;
   }
@@ -461,22 +462,25 @@ GST_ats_update_metrics (const struct GNUNET_PeerIdentity *peer,
        struct GNUNET_ATS_Information *ats_new;
 
   if (GNUNET_NO == GNUNET_ATS_session_known (GST_ats, address, session))
-       return;
+    return;
 
-       /* Call to manipulation to manipulate ATS information */
-       ats_new = GST_manipulation_manipulate_metrics (peer, address, session, ats, ats_count);
-       if (NULL == ats_new)
-       {
-                       GNUNET_break (0);
-                       return;
-       }
-  if (GNUNET_NO == GNUNET_ATS_address_update (GST_ats, address, session, ats_new, ats_count))
+  /* Call to manipulation to manipulate ATS information */
+  ats_new = GST_manipulation_manipulate_metrics (peer, address, session, ats,
+      ats_count);
+  if (NULL == ats_new)
+  {
+    GNUNET_break(0);
+    return;
+  }
+  if (GNUNET_NO == GNUNET_ATS_address_update (GST_ats,
+      address, session, ats_new, ats_count))
   {
-       GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
-                       _("Address or session unknown: failed to update properties for peer `%s' plugin `%s' address `%s' session %p\n"),
-                       GNUNET_i2s (peer), address->transport_name, GST_plugins_a2s (address), session);
+    GNUNET_log(GNUNET_ERROR_TYPE_ERROR,
+        _("Address or session unknown: failed to update properties for peer `%s' plugin `%s' address `%s' session %p\n"),
+        GNUNET_i2s (peer), address->transport_name, GST_plugins_a2s (address),
+        session);
   }
-  GNUNET_free (ats_new);
+  GNUNET_free(ats_new);
 }