-allow caller ID to differ from zone used for resolution
[oweals/gnunet.git] / src / transport / plugin_transport_wlan.c
index 77bb28ebce425a995d92df9955e40dfd19bde796..f0197feb84b2331804dbe89319803b7a052b22e3 100644 (file)
@@ -662,7 +662,7 @@ wlan_plugin_disconnect_session (void *cls,
   struct PendingMessage *pm;
 
   endpoint->plugin->env->session_end (endpoint->plugin->env->cls,
-                                     &session->target,
+                                     session->address,
                                      session);
   while (NULL != (pm = session->pending_message_head))
   {
@@ -1060,7 +1060,7 @@ macendpoint_timeout (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc)
  * Find (or create) a MacEndpoint with a specific MAC address
  *
  * @param plugin pointer to the plugin struct
- * @param addr the MAC address of the endpoint
+ * @param mac the MAC address of the endpoint
  * @return handle to our data structure for this MAC
  */
 static struct MacEndpoint *
@@ -1725,15 +1725,15 @@ wlan_plugin_address_pretty_printer (void *cls, const char *type,
   if (sizeof (struct WlanAddress) != addrlen)
   {
     /* invalid address  */
-    LOG (GNUNET_ERROR_TYPE_WARNING,
-        _("WLAN address with invalid size encountered\n"));
-    asc (asc_cls, NULL);
-    return;
+    asc (asc_cls, NULL, GNUNET_SYSERR);
+  }
+  else
+  {
+    ret = GNUNET_strdup (wlan_plugin_address_to_string(NULL, addr, addrlen));
+    asc (asc_cls, ret, GNUNET_OK);
+    GNUNET_free (ret);
   }
-  ret = GNUNET_strdup (wlan_plugin_address_to_string(NULL, addr, addrlen));
-  asc (asc_cls, ret);
-  GNUNET_free (ret);
-  asc (asc_cls, NULL);
+  asc (asc_cls, NULL, GNUNET_OK);
 }
 
 
@@ -1949,7 +1949,7 @@ libgnunet_plugin_transport_wlan_init (void *cls)
                          0, GNUNET_NO);
   GNUNET_STATISTICS_set (plugin->env->stats, _("# WLAN MAC endpoints allocated"),
                          0, 0);
-  GNUNET_BANDWIDTH_tracker_init (&plugin->tracker,
+  GNUNET_BANDWIDTH_tracker_init (&plugin->tracker, NULL, NULL,
                                  GNUNET_BANDWIDTH_value_init (100 * 1024 *
                                                               1024 / 8), 100);
   plugin->fragment_data_tokenizer = GNUNET_SERVER_mst_create (&process_data, plugin);