* @author Christian Grothoff
*
* TODO:
+ * - need some logging
+ * - need some statistics
+ * - test
+ *
+ * Code cleanup:
* - factor out crc computations from DNS/EXIT/VPN into shared library?
+ *
+ * Design:
* - which code should advertise services? the service model is right
* now a bit odd, especially as this code DOES the exit and knows
* the DNS "name", but OTOH this is clearly NOT the place to advertise
*
* TODO:
* Basics:
+ * - need some logging
+ * - need some statistics
* - test!
* - better message queue management (bounded state, drop oldest/RED?)
* - actually destroy "stale" tunnels once we have too many!
static void
client_disconnect (void *cls, struct GNUNET_SERVER_Client *client)
{
- GNUNET_CONTAINER_multihashmap_iterate (tunnel_map,
- &cleanup_tunnel_client,
- client);
- GNUNET_CONTAINER_multihashmap_iterate (destination_map,
- &cleanup_destination_client,
- client);
+ if (NULL != tunnel_map)
+ GNUNET_CONTAINER_multihashmap_iterate (tunnel_map,
+ &cleanup_tunnel_client,
+ client);
+ if (NULL != destination_map)
+ GNUNET_CONTAINER_multihashmap_iterate (destination_map,
+ &cleanup_destination_client,
+ client);
}