diff options
author | Christian Grothoff <christian@grothoff.org> | 2021-08-14 13:32:31 +0200 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2021-08-14 13:32:31 +0200 |
commit | f4a4a0806bf361ccbd2d0f9bbdc34187cccba6c6 (patch) | |
tree | 5b095579d4cc244f65472477a74c17674d329196 /src/backend/anastasis-httpd_truth_upload.c | |
parent | 71c62583d81f149cef2bdbe13870da70b50f3cbd (diff) | |
download | anastasis-f4a4a0806bf361ccbd2d0f9bbdc34187cccba6c6.tar.gz anastasis-f4a4a0806bf361ccbd2d0f9bbdc34187cccba6c6.tar.bz2 anastasis-f4a4a0806bf361ccbd2d0f9bbdc34187cccba6c6.zip |
-more legwork for new auth method support
Diffstat (limited to 'src/backend/anastasis-httpd_truth_upload.c')
-rw-r--r-- | src/backend/anastasis-httpd_truth_upload.c | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/src/backend/anastasis-httpd_truth_upload.c b/src/backend/anastasis-httpd_truth_upload.c index 451054f..0fb9017 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 = NULL; const char *type; enum GNUNET_DB_QueryStatus qs; uint32_t storage_years; @@ -594,10 +594,12 @@ AH_handler_truth_post ( if (NULL != long_poll_timeout_ms) { unsigned int timeout; + char dummy; if (1 != sscanf (long_poll_timeout_ms, - "%u", - &timeout)) + "%u%c", + &timeout, + &dummy)) { GNUNET_break_op (0); return TALER_MHD_reply_with_error (connection, @@ -779,7 +781,9 @@ AH_handler_truth_post ( qs = db->store_truth (db->cls, truth_uuid, &keyshare_data, - truth_mime, + (NULL == truth_mime) + ? "" + : truth_mime, encrypted_truth, encrypted_truth_size, type, |