diff options
author | Martin Schanzenbach <mschanzenbach@posteo.de> | 2015-03-13 09:59:43 +0000 |
---|---|---|
committer | Martin Schanzenbach <mschanzenbach@posteo.de> | 2015-03-13 09:59:43 +0000 |
commit | 74f9b73e5592424165236164fbb8e65d03399614 (patch) | |
tree | e2c293500d6dc565ee3635b43cf974a4a976c243 /src/gns/plugin_rest_gns.c | |
parent | 0bcb81843084f1b2cde5af408adcddebfb4c5875 (diff) | |
download | gnunet-74f9b73e5592424165236164fbb8e65d03399614.tar.gz gnunet-74f9b73e5592424165236164fbb8e65d03399614.zip |
-bugfixes, change plugin call
Diffstat (limited to 'src/gns/plugin_rest_gns.c')
-rw-r--r-- | src/gns/plugin_rest_gns.c | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/src/gns/plugin_rest_gns.c b/src/gns/plugin_rest_gns.c index 75b0ff288..e837fe963 100644 --- a/src/gns/plugin_rest_gns.c +++ b/src/gns/plugin_rest_gns.c | |||
@@ -567,10 +567,7 @@ parse_json (const char *data, size_t data_size, struct LookupHandle *handle) | |||
567 | * @return GNUNET_OK if request accepted | 567 | * @return GNUNET_OK if request accepted |
568 | */ | 568 | */ |
569 | void | 569 | void |
570 | rest_gns_process_request(const char *method, | 570 | rest_gns_process_request(struct RestConnectionDataHandle *conndata_handle, |
571 | const char *url, | ||
572 | const char *data, | ||
573 | size_t data_size, | ||
574 | GNUNET_REST_ResultProcessor proc, | 571 | GNUNET_REST_ResultProcessor proc, |
575 | void *proc_cls) | 572 | void *proc_cls) |
576 | { | 573 | { |
@@ -578,7 +575,7 @@ rest_gns_process_request(const char *method, | |||
578 | handle->timeout = GNUNET_TIME_UNIT_FOREVER_REL; | 575 | handle->timeout = GNUNET_TIME_UNIT_FOREVER_REL; |
579 | 576 | ||
580 | //parse name and type from url | 577 | //parse name and type from url |
581 | if (GNUNET_OK != parse_url (url, handle)) | 578 | if (GNUNET_OK != parse_url (conndata_handle->url, handle)) |
582 | { | 579 | { |
583 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, "Error parsing url...\n"); | 580 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, "Error parsing url...\n"); |
584 | proc (proc_cls, NULL, 0, GNUNET_SYSERR); | 581 | proc (proc_cls, NULL, 0, GNUNET_SYSERR); |
@@ -588,9 +585,9 @@ rest_gns_process_request(const char *method, | |||
588 | 585 | ||
589 | handle->proc_cls = proc_cls; | 586 | handle->proc_cls = proc_cls; |
590 | handle->proc = proc; | 587 | handle->proc = proc; |
591 | if (0 < data_size) | 588 | if (0 < conndata_handle->data_size) |
592 | { | 589 | { |
593 | if (GNUNET_OK != parse_json (data, data_size, handle)) | 590 | if (GNUNET_OK != parse_json (conndata_handle->data, conndata_handle->data_size, handle)) |
594 | { | 591 | { |
595 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, "Error parsing json...\n"); | 592 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, "Error parsing json...\n"); |
596 | proc (proc_cls, NULL, 0, GNUNET_SYSERR); | 593 | proc (proc_cls, NULL, 0, GNUNET_SYSERR); |