From 48fa0ba8abea2464b2df67247ae1bd50d0f1f934 Mon Sep 17 00:00:00 2001 From: Christian Grothoff Date: Wed, 11 Jun 2014 08:42:40 +0000 Subject: -send proper termination on error --- src/transport/transport_api_address_to_string.c | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) (limited to 'src/transport/transport_api_address_to_string.c') diff --git a/src/transport/transport_api_address_to_string.c b/src/transport/transport_api_address_to_string.c index afd0c7deb..e36904212 100644 --- a/src/transport/transport_api_address_to_string.c +++ b/src/transport/transport_api_address_to_string.c @@ -76,8 +76,7 @@ address_response_processor (void *cls, alucb->cb (alucb->cb_cls, NULL, GNUNET_SYSERR); - GNUNET_CLIENT_disconnect (alucb->client); - GNUNET_free (alucb); + GNUNET_TRANSPORT_address_to_string_cancel (alucb); return; } GNUNET_break (ntohs (msg->type) == @@ -90,8 +89,7 @@ address_response_processor (void *cls, alucb->cb (alucb->cb_cls, NULL, GNUNET_SYSERR); - GNUNET_CLIENT_disconnect (alucb->client); - GNUNET_free (alucb); + GNUNET_TRANSPORT_address_to_string_cancel (alucb); return; } atsm = (const struct AddressToStringResultMessage *) msg; @@ -126,8 +124,7 @@ address_response_processor (void *cls, alucb->cb (alucb->cb_cls, NULL, GNUNET_OK); - GNUNET_CLIENT_disconnect (alucb->client); - GNUNET_free (alucb); + GNUNET_TRANSPORT_address_to_string_cancel (alucb); return; } address = (const char *) &atsm[1]; @@ -139,8 +136,7 @@ address_response_processor (void *cls, alucb->cb (alucb->cb_cls, NULL, GNUNET_SYSERR); - GNUNET_CLIENT_disconnect (alucb->client); - GNUNET_free (alucb); + GNUNET_TRANSPORT_address_to_string_cancel (alucb); return; } /* expect more replies */ -- cgit v1.2.3