aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/transport/plugin_transport_unix.c8
-rw-r--r--src/transport/test_plugin_transport.c23
2 files changed, 31 insertions, 0 deletions
diff --git a/src/transport/plugin_transport_unix.c b/src/transport/plugin_transport_unix.c
index 55787a7f9..2a7af356f 100644
--- a/src/transport/plugin_transport_unix.c
+++ b/src/transport/plugin_transport_unix.c
@@ -1363,11 +1363,19 @@ libgnunet_plugin_transport_unix_done (void *cls)
1363 GNUNET_free (api); 1363 GNUNET_free (api);
1364 return NULL; 1364 return NULL;
1365 } 1365 }
1366
1367 plugin->env->notify_address (plugin->env->cls, GNUNET_NO,
1368 plugin->unix_socket_path,
1369 strlen (plugin->unix_socket_path) + 1,
1370 "unix");
1371
1366 unix_transport_server_stop (plugin); 1372 unix_transport_server_stop (plugin);
1367 1373
1374
1368 GNUNET_CONTAINER_multihashmap_iterate (plugin->session_map, &get_session_delete_it, plugin); 1375 GNUNET_CONTAINER_multihashmap_iterate (plugin->session_map, &get_session_delete_it, plugin);
1369 GNUNET_CONTAINER_multihashmap_destroy (plugin->session_map); 1376 GNUNET_CONTAINER_multihashmap_destroy (plugin->session_map);
1370 1377
1378
1371 if (NULL != plugin->rs) 1379 if (NULL != plugin->rs)
1372 GNUNET_NETWORK_fdset_destroy (plugin->rs); 1380 GNUNET_NETWORK_fdset_destroy (plugin->rs);
1373 if (NULL != plugin->ws) 1381 if (NULL != plugin->ws)
diff --git a/src/transport/test_plugin_transport.c b/src/transport/test_plugin_transport.c
index 6632244e2..3bd0b7cb0 100644
--- a/src/transport/test_plugin_transport.c
+++ b/src/transport/test_plugin_transport.c
@@ -142,6 +142,9 @@ struct AddressWrapper
142static void 142static void
143end () 143end ()
144{ 144{
145 struct AddressWrapper *w;
146 int c = 0;
147
145 if (GNUNET_SCHEDULER_NO_TASK != timeout_task) 148 if (GNUNET_SCHEDULER_NO_TASK != timeout_task)
146 { 149 {
147 GNUNET_SCHEDULER_cancel (timeout_task); 150 GNUNET_SCHEDULER_cancel (timeout_task);
@@ -149,6 +152,26 @@ end ()
149 } 152 }
150 if (NULL != api) 153 if (NULL != api)
151 GNUNET_PLUGIN_unload (libname, api); 154 GNUNET_PLUGIN_unload (libname, api);
155
156 while (NULL != head)
157 {
158 w = head;
159 GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
160 _("Plugin did not remove address `%s' \n"), w->addrstring);
161 GNUNET_CONTAINER_DLL_remove (head, tail, w);
162 c ++;
163 GNUNET_free (w->addr);
164 GNUNET_free (w->addrstring);
165 GNUNET_free (w);
166 }
167 if (c > 0)
168 {
169 GNUNET_break (0);
170 GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
171 _("Plugin did not remove %u addresses \n"), c);
172 }
173
174
152 GNUNET_free (libname); 175 GNUNET_free (libname);
153 libname = NULL; 176 libname = NULL;
154 GNUNET_STATISTICS_destroy (stats, GNUNET_NO); 177 GNUNET_STATISTICS_destroy (stats, GNUNET_NO);