summaryrefslogtreecommitdiff
path: root/src/reducer/anastasis_api_backup_redux.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2022-04-05 17:16:04 +0200
committerChristian Grothoff <christian@grothoff.org>2022-04-05 17:16:04 +0200
commit71f889186973ef26e8ae684ec47fd570138bc4e5 (patch)
tree02898d03575384c26b5399d28d702d97f4683403 /src/reducer/anastasis_api_backup_redux.c
parent452aa5391b75ab6637b62398f9b0627593570d5d (diff)
downloadanastasis-71f889186973ef26e8ae684ec47fd570138bc4e5.tar.gz
anastasis-71f889186973ef26e8ae684ec47fd570138bc4e5.tar.bz2
anastasis-71f889186973ef26e8ae684ec47fd570138bc4e5.zip
adapt to latest GNUnet API: GNUNET_JSON_spec_mark_optional() changed
Diffstat (limited to 'src/reducer/anastasis_api_backup_redux.c')
-rw-r--r--src/reducer/anastasis_api_backup_redux.c81
1 files changed, 54 insertions, 27 deletions
diff --git a/src/reducer/anastasis_api_backup_redux.c b/src/reducer/anastasis_api_backup_redux.c
index b3ee9dd..4d14479 100644
--- a/src/reducer/anastasis_api_backup_redux.c
+++ b/src/reducer/anastasis_api_backup_redux.c
@@ -357,16 +357,20 @@ add_authentication (json_t *state,
struct GNUNET_JSON_Specification ispec[] = {
GNUNET_JSON_spec_mark_optional (
GNUNET_JSON_spec_uint32 ("storage_limit_in_megabytes",
- &size_limit_in_mb)),
+ &size_limit_in_mb),
+ NULL),
GNUNET_JSON_spec_mark_optional (
GNUNET_JSON_spec_uint32 ("http_status",
- &http_status)),
+ &http_status),
+ NULL),
GNUNET_JSON_spec_mark_optional (
GNUNET_JSON_spec_bool ("disabled",
- &disabled)),
+ &disabled),
+ NULL),
GNUNET_JSON_spec_mark_optional (
GNUNET_JSON_spec_json ("methods",
- &methods)),
+ &methods),
+ NULL),
GNUNET_JSON_spec_end ()
};
@@ -1165,10 +1169,12 @@ provider_candidate (struct PolicyBuilder *pb,
struct GNUNET_JSON_Specification spec[] = {
GNUNET_JSON_spec_mark_optional (
GNUNET_JSON_spec_bool ("disabled",
- &disabled)),
+ &disabled),
+ NULL),
GNUNET_JSON_spec_mark_optional (
GNUNET_JSON_spec_uint32 ("http_status",
- &http_status)),
+ &http_status),
+ NULL),
GNUNET_JSON_spec_end ()
};
@@ -1967,10 +1973,12 @@ add_policy (json_t *state,
struct GNUNET_JSON_Specification spec[] = {
GNUNET_JSON_spec_mark_optional (
GNUNET_JSON_spec_bool ("disabled",
- &disabled)),
+ &disabled),
+ NULL),
GNUNET_JSON_spec_mark_optional (
GNUNET_JSON_spec_uint32 ("http_status",
- &http_status)),
+ &http_status),
+ NULL),
GNUNET_JSON_spec_uint32 ("storage_limit_in_megabytes",
&limit),
GNUNET_JSON_spec_json ("methods",
@@ -2447,10 +2455,12 @@ update_expiration_cost (json_t *state,
struct GNUNET_JSON_Specification pspec[] = {
GNUNET_JSON_spec_mark_optional (
GNUNET_JSON_spec_bool ("disabled",
- &disabled)),
+ &disabled),
+ NULL),
GNUNET_JSON_spec_mark_optional (
GNUNET_JSON_spec_uint32 ("http_status",
- &http_status)),
+ &http_status),
+ NULL),
TALER_JSON_spec_amount_any ("annual_fee",
&annual_fee),
GNUNET_JSON_spec_end ()
@@ -2554,10 +2564,12 @@ update_expiration_cost (json_t *state,
struct GNUNET_JSON_Specification pspec[] = {
GNUNET_JSON_spec_mark_optional (
GNUNET_JSON_spec_bool ("disabled",
- &disabled)),
+ &disabled),
+ NULL),
GNUNET_JSON_spec_mark_optional (
GNUNET_JSON_spec_uint32 ("http_status",
- &http_status)),
+ &http_status),
+ NULL),
TALER_JSON_spec_amount_any ("truth_upload_fee",
&upload_cost),
GNUNET_JSON_spec_end ()
@@ -2682,7 +2694,8 @@ done_policy_review (json_t *state,
struct GNUNET_JSON_Specification spec[] = {
GNUNET_JSON_spec_mark_optional (
GNUNET_JSON_spec_timestamp ("expiration",
- &exp)),
+ &exp),
+ NULL),
GNUNET_JSON_spec_end ()
};
@@ -3137,7 +3150,8 @@ share_secret (struct UploadContext *uc)
&core_secret),
GNUNET_JSON_spec_mark_optional (
GNUNET_JSON_spec_string ("secret_name",
- &secret_name)),
+ &secret_name),
+ NULL),
GNUNET_JSON_spec_end ()
};
@@ -3159,7 +3173,8 @@ share_secret (struct UploadContext *uc)
struct GNUNET_JSON_Specification pspec[] = {
GNUNET_JSON_spec_mark_optional (
GNUNET_JSON_spec_relative_time ("timeout",
- &timeout)),
+ &timeout),
+ NULL),
GNUNET_JSON_spec_end ()
};
@@ -3259,7 +3274,8 @@ share_secret (struct UploadContext *uc)
struct GNUNET_JSON_Specification ispec[] = {
GNUNET_JSON_spec_mark_optional (
GNUNET_JSON_spec_json ("truth",
- &jtruth)),
+ &jtruth),
+ NULL),
GNUNET_JSON_spec_string ("provider",
&provider_url),
GNUNET_JSON_spec_uint32 ("authentication_method",
@@ -3362,7 +3378,8 @@ share_secret (struct UploadContext *uc)
struct GNUNET_JSON_Specification ispec[] = {
GNUNET_JSON_spec_mark_optional (
GNUNET_JSON_spec_fixed_auto ("payment_secret",
- &pds[i].payment_secret)),
+ &pds[i].payment_secret),
+ NULL),
GNUNET_JSON_spec_string ("provider_url",
&pds[i].provider_url),
GNUNET_JSON_spec_end ()
@@ -3609,7 +3626,8 @@ add_truth_object (struct UploadContext *uc,
struct GNUNET_JSON_Specification spec[] = {
GNUNET_JSON_spec_mark_optional (
GNUNET_JSON_spec_uint32 ("upload_status",
- &status)),
+ &status),
+ NULL),
GNUNET_JSON_spec_end ()
};
if (GNUNET_OK !=
@@ -3793,10 +3811,12 @@ check_truth_upload (struct UploadContext *uc,
&type),
GNUNET_JSON_spec_mark_optional (
GNUNET_JSON_spec_string ("mime_type",
- &mime_type)),
+ &mime_type),
+ NULL),
GNUNET_JSON_spec_mark_optional (
GNUNET_JSON_spec_string ("instructions",
- &instructions)),
+ &instructions),
+ NULL),
GNUNET_JSON_spec_varsize ("challenge",
&truth_data,
&truth_data_size),
@@ -3984,7 +4004,8 @@ upload (json_t *state,
struct GNUNET_JSON_Specification pspec[] = {
GNUNET_JSON_spec_mark_optional (
GNUNET_JSON_spec_relative_time ("timeout",
- &uc->timeout)),
+ &uc->timeout),
+ NULL),
GNUNET_JSON_spec_end ()
};
@@ -4043,7 +4064,8 @@ upload (json_t *state,
&am_idx),
GNUNET_JSON_spec_mark_optional (
GNUNET_JSON_spec_json ("truth",
- &truth)),
+ &truth),
+ NULL),
GNUNET_JSON_spec_end ()
};
@@ -4206,13 +4228,16 @@ check_upload_size_limit (json_t *state,
struct GNUNET_JSON_Specification spec[] = {
GNUNET_JSON_spec_mark_optional (
GNUNET_JSON_spec_bool ("disabled",
- &disabled)),
+ &disabled),
+ NULL),
GNUNET_JSON_spec_mark_optional (
GNUNET_JSON_spec_uint32 ("http_status",
- &http_status)),
+ &http_status),
+ NULL),
GNUNET_JSON_spec_mark_optional (
GNUNET_JSON_spec_uint32 ("storage_limit_in_megabytes",
- &limit)),
+ &limit),
+ NULL),
GNUNET_JSON_spec_end ()
};
@@ -4265,7 +4290,8 @@ enter_secret (json_t *state,
&jsecret),
GNUNET_JSON_spec_mark_optional (
GNUNET_JSON_spec_timestamp ("expiration",
- &expiration)),
+ &expiration),
+ NULL),
GNUNET_JSON_spec_end ()
};
@@ -5037,7 +5063,8 @@ ANASTASIS_REDUX_backup_begin_ (json_t *state,
struct GNUNET_JSON_Specification spec[] = {
GNUNET_JSON_spec_mark_optional (
GNUNET_JSON_spec_bool ("disabled",
- &disabled)),
+ &disabled),
+ NULL),
GNUNET_JSON_spec_end ()
};