- fix for bug #0002291
authorMatthias Wachs <wachs@net.in.tum.de>
Wed, 2 May 2012 08:04:56 +0000 (08:04 +0000)
committerMatthias Wachs <wachs@net.in.tum.de>
Wed, 2 May 2012 08:04:56 +0000 (08:04 +0000)
src/transport/plugin_transport_unix.c

index 2aa987914276e554ba104d57abcf0354453dfcff..fa491dfcb9e317d738345e76358c6e3fffb098aa 100644 (file)
@@ -1123,8 +1123,10 @@ libgnunet_plugin_transport_unix_done (void *cls)
   GNUNET_CONTAINER_multihashmap_iterate (plugin->session_map, &get_session_delete_it, plugin);
   GNUNET_CONTAINER_multihashmap_destroy (plugin->session_map);
 
-  GNUNET_NETWORK_fdset_destroy (plugin->rs);
-  GNUNET_NETWORK_fdset_destroy (plugin->ws);
+  if (NULL != plugin->rs)
+    GNUNET_NETWORK_fdset_destroy (plugin->rs);
+  if (NULL != plugin->ws)
+    GNUNET_NETWORK_fdset_destroy (plugin->ws);
   GNUNET_free (plugin->unix_socket_path);
   GNUNET_free (plugin);
   GNUNET_free (api);