ats_ril: - removed some redundantly saved plugin environment attributes
[oweals/gnunet.git] / src / ats / gnunet-service-ats_performance.c
index bb7ed7934e98ffecc24feb1c37d7073f353dd647..d94b0a7e62a408fe16bb2611edf45ae664da9586 100644 (file)
@@ -258,9 +258,6 @@ peerinfo_it (void *cls,
   if (NULL == id)
     return;
 
-  if (GNUNET_NO == active)
-    return;
-
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
               "Callback for peer `%s' plugin `%s' BW out %llu, BW in %llu \n",
               GNUNET_i2s (id),
@@ -312,6 +309,10 @@ GAS_performance_add_client (struct GNUNET_SERVER_Client *client,
   pc = GNUNET_malloc (sizeof (struct PerformanceClient));
   pc->client = client;
   pc->flag = flag;
+
+  GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Adding performance client %s PIC\n",
+      (flag == START_FLAG_PERFORMANCE_WITH_PIC) ? "with" : "without");
+
   GNUNET_SERVER_notification_context_add (nc, client);
   GNUNET_CONTAINER_DLL_insert (pc_head, pc_tail, pc);
 
@@ -676,7 +677,7 @@ GAS_handle_preference_feedback (void *cls,
     return;
   }
   msg = (const struct FeedbackPreferenceMessage *) message;
-  nump = ntohl (msg->num_preferences);
+  nump = ntohl (msg->num_feedback);
   if (msize !=
       sizeof (struct FeedbackPreferenceMessage) +
       nump * sizeof (struct PreferenceInformation))
@@ -692,6 +693,7 @@ GAS_handle_preference_feedback (void *cls,
     GAS_addresses_preference_feedback (GSA_addresses,
                                      client,
                                      &msg->peer,
+                                     GNUNET_TIME_relative_ntoh(msg->scope),
                                      (enum GNUNET_ATS_PreferenceKind)
                                      ntohl (pi[i].preference_kind),
                                      pi[i].preference_value);