aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMartin Schanzenbach <mschanzenbach@posteo.de>2015-03-27 13:40:35 +0000
committerMartin Schanzenbach <mschanzenbach@posteo.de>2015-03-27 13:40:35 +0000
commit7c360cc7c7252bdf740b4e5186f1a852f002b13b (patch)
tree8d7958407db1881767abd334b97f1b7baa249a82 /src
parentb18ef62fd8970e1bfb2b3958cee855e2b732d94b (diff)
downloadgnunet-7c360cc7c7252bdf740b4e5186f1a852f002b13b.tar.gz
gnunet-7c360cc7c7252bdf740b4e5186f1a852f002b13b.zip
-PUT since MHD cannot PATCH; add config
Diffstat (limited to 'src')
-rw-r--r--src/identity/plugin_rest_identity.c2
-rw-r--r--src/rest/gnunet-rest-server.c4
-rw-r--r--src/rest/rest.conf3
3 files changed, 5 insertions, 4 deletions
diff --git a/src/identity/plugin_rest_identity.c b/src/identity/plugin_rest_identity.c
index e672c70ef..181a21c12 100644
--- a/src/identity/plugin_rest_identity.c
+++ b/src/identity/plugin_rest_identity.c
@@ -658,7 +658,7 @@ init_cont (struct RequestHandle *handle)
658 static const struct GNUNET_REST_RestConnectionHandler handlers[] = { 658 static const struct GNUNET_REST_RestConnectionHandler handlers[] = {
659 {MHD_HTTP_METHOD_GET, GNUNET_REST_API_NS_IDENTITY, &ego_info_response}, 659 {MHD_HTTP_METHOD_GET, GNUNET_REST_API_NS_IDENTITY, &ego_info_response},
660 {MHD_HTTP_METHOD_POST, GNUNET_REST_API_NS_IDENTITY, &ego_create_cont}, 660 {MHD_HTTP_METHOD_POST, GNUNET_REST_API_NS_IDENTITY, &ego_create_cont},
661 {MHD_HTTP_METHOD_PATCH, GNUNET_REST_API_NS_IDENTITY, &ego_edit_cont}, 661 {MHD_HTTP_METHOD_PUT, GNUNET_REST_API_NS_IDENTITY, &ego_edit_cont},
662 {MHD_HTTP_METHOD_DELETE, GNUNET_REST_API_NS_IDENTITY, &ego_delete_cont}, 662 {MHD_HTTP_METHOD_DELETE, GNUNET_REST_API_NS_IDENTITY, &ego_delete_cont},
663 GNUNET_REST_HANDLER_END 663 GNUNET_REST_HANDLER_END
664 }; 664 };
diff --git a/src/rest/gnunet-rest-server.c b/src/rest/gnunet-rest-server.c
index aa95e48b3..c9c7d64bf 100644
--- a/src/rest/gnunet-rest-server.c
+++ b/src/rest/gnunet-rest-server.c
@@ -773,12 +773,10 @@ main (int argc, char *const *argv)
773 773
774 if (GNUNET_OK != GNUNET_STRINGS_get_utf8_args (argc, argv, &argc, &argv)) 774 if (GNUNET_OK != GNUNET_STRINGS_get_utf8_args (argc, argv, &argc, &argv))
775 return 2; 775 return 2;
776 GNUNET_log_setup ("gnunet-rest-service", "WARNING", NULL); 776 GNUNET_log_setup ("gnunet-rest-server", "WARNING", NULL);
777 failure_response = MHD_create_response_from_buffer (strlen(err_page), 777 failure_response = MHD_create_response_from_buffer (strlen(err_page),
778 (void*)err_page, 778 (void*)err_page,
779 MHD_RESPMEM_PERSISTENT); 779 MHD_RESPMEM_PERSISTENT);
780 GNUNET_log (GNUNET_ERROR_TYPE_INFO,
781 "Start\n");
782 ret = 780 ret =
783 (GNUNET_OK == 781 (GNUNET_OK ==
784 GNUNET_PROGRAM_run (argc, argv, "gnunet-rest-server", 782 GNUNET_PROGRAM_run (argc, argv, "gnunet-rest-server",
diff --git a/src/rest/rest.conf b/src/rest/rest.conf
index e69de29bb..febc51486 100644
--- a/src/rest/rest.conf
+++ b/src/rest/rest.conf
@@ -0,0 +1,3 @@
1[rest]
2BINARY=gnunet-rest-server
3REST_PORT=7776