From 71c62583d81f149cef2bdbe13870da70b50f3cbd Mon Sep 17 00:00:00 2001 From: Christian Grothoff Date: Sat, 14 Aug 2021 10:45:50 +0200 Subject: -improve docs on what truth is, make truth_mime optional --- src/backend/anastasis-httpd_truth_upload.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'src/backend/anastasis-httpd_truth_upload.c') diff --git a/src/backend/anastasis-httpd_truth_upload.c b/src/backend/anastasis-httpd_truth_upload.c index ada4d4c..451054f 100644 --- a/src/backend/anastasis-httpd_truth_upload.c +++ b/src/backend/anastasis-httpd_truth_upload.c @@ -522,7 +522,7 @@ AH_handler_truth_post ( struct ANASTASIS_CRYPTO_EncryptedKeyShareP keyshare_data; void *encrypted_truth; size_t encrypted_truth_size; - const char *truth_mime; + const char *truth_mime = ""; const char *type; enum GNUNET_DB_QueryStatus qs; uint32_t storage_years; @@ -535,8 +535,9 @@ AH_handler_truth_post ( GNUNET_JSON_spec_varsize ("encrypted_truth", &encrypted_truth, &encrypted_truth_size), - GNUNET_JSON_spec_string ("truth_mime", - &truth_mime), + GNUNET_JSON_spec_mark_optional ( + GNUNET_JSON_spec_string ("truth_mime", + &truth_mime)), GNUNET_JSON_spec_uint32 ("storage_duration_years", &storage_years), GNUNET_JSON_spec_end () -- cgit v1.2.3