aboutsummaryrefslogtreecommitdiff
path: root/src/arm/arm_api.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/arm/arm_api.c')
-rw-r--r--src/arm/arm_api.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/arm/arm_api.c b/src/arm/arm_api.c
index c352cbdae..bb4b355fc 100644
--- a/src/arm/arm_api.c
+++ b/src/arm/arm_api.c
@@ -128,7 +128,7 @@ service_shutdown_handler (void *cls, const struct GNUNET_MessageHeader *msg)
128 } 128 }
129 } 129 }
130 GNUNET_SCHEDULER_cancel (shutdown_ctx->cancel_task); 130 GNUNET_SCHEDULER_cancel (shutdown_ctx->cancel_task);
131 GNUNET_CLIENT_disconnect (shutdown_ctx->sock, GNUNET_NO); 131 GNUNET_CLIENT_disconnect (shutdown_ctx->sock);
132 GNUNET_free (shutdown_ctx); 132 GNUNET_free (shutdown_ctx);
133 return; 133 return;
134 } 134 }
@@ -142,7 +142,7 @@ service_shutdown_handler (void *cls, const struct GNUNET_MessageHeader *msg)
142 /* ARM is not shutting down, well, report the error and be done with it... */ 142 /* ARM is not shutting down, well, report the error and be done with it... */
143 shutdown_ctx->cont (shutdown_ctx->cont_cls, shutdown_ctx->confirmed); 143 shutdown_ctx->cont (shutdown_ctx->cont_cls, shutdown_ctx->confirmed);
144 GNUNET_SCHEDULER_cancel (shutdown_ctx->cancel_task); 144 GNUNET_SCHEDULER_cancel (shutdown_ctx->cancel_task);
145 GNUNET_CLIENT_disconnect (shutdown_ctx->sock, GNUNET_NO); 145 GNUNET_CLIENT_disconnect (shutdown_ctx->sock);
146 GNUNET_free (shutdown_ctx); 146 GNUNET_free (shutdown_ctx);
147 return; 147 return;
148 } 148 }
@@ -165,7 +165,7 @@ service_shutdown_cancel (void *cls,
165 struct ShutdownContext *shutdown_ctx = cls; 165 struct ShutdownContext *shutdown_ctx = cls;
166 166
167 shutdown_ctx->cont (shutdown_ctx->cont_cls, GNUNET_ARM_PROCESS_COMMUNICATION_TIMEOUT); 167 shutdown_ctx->cont (shutdown_ctx->cont_cls, GNUNET_ARM_PROCESS_COMMUNICATION_TIMEOUT);
168 GNUNET_CLIENT_disconnect (shutdown_ctx->sock, GNUNET_NO); 168 GNUNET_CLIENT_disconnect (shutdown_ctx->sock);
169 GNUNET_free (shutdown_ctx); 169 GNUNET_free (shutdown_ctx);
170} 170}
171 171
@@ -191,7 +191,7 @@ write_shutdown (void *cls, size_t size, void *buf)
191 LOG (GNUNET_ERROR_TYPE_WARNING, 191 LOG (GNUNET_ERROR_TYPE_WARNING,
192 _("Failed to transmit shutdown request to client.\n")); 192 _("Failed to transmit shutdown request to client.\n"));
193 shutdown_ctx->cont (shutdown_ctx->cont_cls, GNUNET_ARM_PROCESS_COMMUNICATION_ERROR); 193 shutdown_ctx->cont (shutdown_ctx->cont_cls, GNUNET_ARM_PROCESS_COMMUNICATION_ERROR);
194 GNUNET_CLIENT_disconnect (shutdown_ctx->sock, GNUNET_NO); 194 GNUNET_CLIENT_disconnect (shutdown_ctx->sock);
195 GNUNET_free (shutdown_ctx); 195 GNUNET_free (shutdown_ctx);
196 return 0; /* client disconnected */ 196 return 0; /* client disconnected */
197 } 197 }
@@ -273,7 +273,7 @@ void
273GNUNET_ARM_disconnect (struct GNUNET_ARM_Handle *h) 273GNUNET_ARM_disconnect (struct GNUNET_ARM_Handle *h)
274{ 274{
275 if (h->client != NULL) 275 if (h->client != NULL)
276 GNUNET_CLIENT_disconnect (h->client, GNUNET_NO); 276 GNUNET_CLIENT_disconnect (h->client);
277 GNUNET_CONFIGURATION_destroy (h->cfg); 277 GNUNET_CONFIGURATION_destroy (h->cfg);
278 GNUNET_free (h); 278 GNUNET_free (h);
279} 279}
@@ -471,7 +471,7 @@ handle_response (void *cls, const struct GNUNET_MessageHeader *msg)
471 ("Error receiving response to `%s' request from ARM for service `%s'\n"), 471 ("Error receiving response to `%s' request from ARM for service `%s'\n"),
472 (sc->type == GNUNET_MESSAGE_TYPE_ARM_START) ? "START" : "STOP", 472 (sc->type == GNUNET_MESSAGE_TYPE_ARM_START) ? "START" : "STOP",
473 (const char *) &sc[1]); 473 (const char *) &sc[1]);
474 GNUNET_CLIENT_disconnect (sc->h->client, GNUNET_NO); 474 GNUNET_CLIENT_disconnect (sc->h->client);
475 sc->h->client = GNUNET_CLIENT_connect ("arm", sc->h->cfg); 475 sc->h->client = GNUNET_CLIENT_connect ("arm", sc->h->cfg);
476 GNUNET_assert (NULL != sc->h->client); 476 GNUNET_assert (NULL != sc->h->client);
477 if (sc->callback != NULL) 477 if (sc->callback != NULL)
@@ -730,7 +730,7 @@ handle_list_response (void *cls, const struct GNUNET_MessageHeader *msg)
730 { 730 {
731 LOG (GNUNET_ERROR_TYPE_WARNING, 731 LOG (GNUNET_ERROR_TYPE_WARNING,
732 "Error receiving response to LIST request from ARM\n"); 732 "Error receiving response to LIST request from ARM\n");
733 GNUNET_CLIENT_disconnect (sc->h->client, GNUNET_NO); 733 GNUNET_CLIENT_disconnect (sc->h->client);
734 sc->h->client = GNUNET_CLIENT_connect ("arm", sc->h->cfg); 734 sc->h->client = GNUNET_CLIENT_connect ("arm", sc->h->cfg);
735 GNUNET_assert (NULL != sc->h->client); 735 GNUNET_assert (NULL != sc->h->client);
736 if (sc->callback != NULL) 736 if (sc->callback != NULL)