summaryrefslogtreecommitdiff
path: root/src/lib
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2020-12-12 22:42:33 +0100
committerChristian Grothoff <christian@grothoff.org>2020-12-12 22:42:33 +0100
commit0847e16ea5d338c4281963d2efa0bd94c37bd188 (patch)
tree7c9ede4db3db927c16fdbc6524a11c4c72088442 /src/lib
parent744274480959110374ba2036d5b1a691a06df468 (diff)
downloadexchange-0847e16ea5d338c4281963d2efa0bd94c37bd188.tar.gz
exchange-0847e16ea5d338c4281963d2efa0bd94c37bd188.tar.bz2
exchange-0847e16ea5d338c4281963d2efa0bd94c37bd188.zip
fix misc bugs
Diffstat (limited to 'src/lib')
-rw-r--r--src/lib/exchange_api_management_get_keys.c28
1 files changed, 16 insertions, 12 deletions
diff --git a/src/lib/exchange_api_management_get_keys.c b/src/lib/exchange_api_management_get_keys.c
index 35b191a1f..c6548a341 100644
--- a/src/lib/exchange_api_management_get_keys.c
+++ b/src/lib/exchange_api_management_get_keys.c
@@ -163,20 +163,18 @@ handle_ok (struct TALER_EXCHANGE_ManagementGetKeysHandle *gh,
= &fk.denom_keys[i];
const char *section_name;
struct GNUNET_JSON_Specification spec[] = {
- GNUNET_JSON_spec_string ("section_name",
- &section_name),
- GNUNET_JSON_spec_fixed_auto ("denom_secmod_sig",
- &denom_key->denom_secmod_sig),
- TALER_JSON_spec_absolute_time ("stamp_expire_deposit",
- &denom_key->expire_deposit),
- TALER_JSON_spec_absolute_time ("stamp_expire_withdraw",
- &denom_key->withdraw_valid_until),
+ TALER_JSON_spec_amount ("value",
+ &denom_key->value),
TALER_JSON_spec_absolute_time ("stamp_start",
&denom_key->valid_from),
+ TALER_JSON_spec_absolute_time ("stamp_expire_withdraw",
+ &denom_key->withdraw_valid_until),
+ TALER_JSON_spec_absolute_time ("stamp_expire_deposit",
+ &denom_key->expire_deposit),
TALER_JSON_spec_absolute_time ("stamp_expire_legal",
&denom_key->expire_legal),
- TALER_JSON_spec_amount ("value",
- &denom_key->value),
+ GNUNET_JSON_spec_rsa_public_key ("denom_pub",
+ &denom_key->key.rsa_public_key),
TALER_JSON_spec_amount ("fee_withdraw",
&denom_key->fee_withdraw),
TALER_JSON_spec_amount ("fee_deposit",
@@ -185,8 +183,10 @@ handle_ok (struct TALER_EXCHANGE_ManagementGetKeysHandle *gh,
&denom_key->fee_refresh),
TALER_JSON_spec_amount ("fee_refund",
&denom_key->fee_refund),
- GNUNET_JSON_spec_rsa_public_key ("denom_pub",
- &denom_key->key.rsa_public_key),
+ GNUNET_JSON_spec_fixed_auto ("denom_secmod_sig",
+ &denom_key->denom_secmod_sig),
+ GNUNET_JSON_spec_string ("section_name",
+ &section_name),
GNUNET_JSON_spec_end ()
};
@@ -196,6 +196,9 @@ handle_ok (struct TALER_EXCHANGE_ManagementGetKeysHandle *gh,
NULL, NULL))
{
GNUNET_break_op (0);
+ json_dumpf (j,
+ stderr,
+ JSON_INDENT (2));
ok = false;
break;
}
@@ -221,6 +224,7 @@ handle_ok (struct TALER_EXCHANGE_ManagementGetKeysHandle *gh,
break;
}
}
+ GNUNET_JSON_parse_free (spec);
}
if (ok)
{