aboutsummaryrefslogtreecommitdiff
path: root/src/reclaim/plugin_rest_reclaim.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/reclaim/plugin_rest_reclaim.c')
-rw-r--r--src/reclaim/plugin_rest_reclaim.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/reclaim/plugin_rest_reclaim.c b/src/reclaim/plugin_rest_reclaim.c
index eb442bc3b..c2d14825e 100644
--- a/src/reclaim/plugin_rest_reclaim.c
+++ b/src/reclaim/plugin_rest_reclaim.c
@@ -331,6 +331,7 @@ finished_cont (void *cls, int32_t success, const char *emsg)
331 331
332 resp = GNUNET_REST_create_response (emsg); 332 resp = GNUNET_REST_create_response (emsg);
333 MHD_add_response_header (resp, "Content-Type", "application/json"); 333 MHD_add_response_header (resp, "Content-Type", "application/json");
334 MHD_add_response_header (resp, "Access-Control-Allow-Methods", allow_methods);
334 if (GNUNET_OK != success) 335 if (GNUNET_OK != success)
335 { 336 {
336 GNUNET_SCHEDULER_add_now (&do_error, handle); 337 GNUNET_SCHEDULER_add_now (&do_error, handle);
@@ -348,6 +349,7 @@ delete_finished_cb (void *cls, int32_t success, const char *emsg)
348 struct MHD_Response *resp; 349 struct MHD_Response *resp;
349 350
350 resp = GNUNET_REST_create_response (emsg); 351 resp = GNUNET_REST_create_response (emsg);
352 MHD_add_response_header (resp, "Access-Control-Allow-Methods", allow_methods);
351 if (GNUNET_OK != success) 353 if (GNUNET_OK != success)
352 { 354 {
353 GNUNET_SCHEDULER_add_now (&do_error, handle); 355 GNUNET_SCHEDULER_add_now (&do_error, handle);
@@ -373,6 +375,7 @@ return_response (void *cls)
373 result_str = json_dumps (handle->resp_object, 0); 375 result_str = json_dumps (handle->resp_object, 0);
374 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Result %s\n", result_str); 376 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Result %s\n", result_str);
375 resp = GNUNET_REST_create_response (result_str); 377 resp = GNUNET_REST_create_response (result_str);
378 MHD_add_response_header (resp, "Access-Control-Allow-Methods", allow_methods);
376 handle->proc (handle->proc_cls, resp, MHD_HTTP_OK); 379 handle->proc (handle->proc_cls, resp, MHD_HTTP_OK);
377 GNUNET_free (result_str); 380 GNUNET_free (result_str);
378 cleanup_handle (handle); 381 cleanup_handle (handle);