summaryrefslogtreecommitdiff
path: root/src/lib/testing_api_cmd_withdraw.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2020-01-17 17:29:35 +0100
committerChristian Grothoff <christian@grothoff.org>2020-01-17 17:29:44 +0100
commit2ffabd394cf9c25b9829ee1733d7f008322e4142 (patch)
treed9a9c9d1476977731e62f0267884c7cbba68acb5 /src/lib/testing_api_cmd_withdraw.c
parent5a03bb71b5b4dd5d3f6fb78ae863caec9b9e06f4 (diff)
downloadexchange-2ffabd394cf9c25b9829ee1733d7f008322e4142.tar.gz
exchange-2ffabd394cf9c25b9829ee1733d7f008322e4142.tar.bz2
exchange-2ffabd394cf9c25b9829ee1733d7f008322e4142.zip
fix reserve_pub-via-reserve_priv FIXME
Diffstat (limited to 'src/lib/testing_api_cmd_withdraw.c')
-rw-r--r--src/lib/testing_api_cmd_withdraw.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/lib/testing_api_cmd_withdraw.c b/src/lib/testing_api_cmd_withdraw.c
index 09ab234dd..5ebec44c5 100644
--- a/src/lib/testing_api_cmd_withdraw.c
+++ b/src/lib/testing_api_cmd_withdraw.c
@@ -350,6 +350,7 @@ withdraw_traits (void *cls,
struct WithdrawState *ws = cls;
const struct TALER_TESTING_Command *reserve_cmd;
const struct TALER_ReservePrivateKeyP *reserve_priv;
+ const struct TALER_ReservePublicKeyP *reserve_pub;
/* We offer the reserve key where these coins were withdrawn
* from. */
@@ -372,6 +373,15 @@ withdraw_traits (void *cls,
TALER_TESTING_interpreter_fail (ws->is);
return GNUNET_SYSERR;
}
+ if (GNUNET_OK !=
+ TALER_TESTING_get_trait_reserve_pub (reserve_cmd,
+ 0,
+ &reserve_pub))
+ {
+ GNUNET_break (0);
+ TALER_TESTING_interpreter_fail (ws->is);
+ return GNUNET_SYSERR;
+ }
if (NULL == ws->exchange_url)
ws->exchange_url
= GNUNET_strdup (TALER_EXCHANGE_get_base_url (ws->is->exchange));
@@ -387,6 +397,8 @@ withdraw_traits (void *cls,
&ws->sig),
TALER_TESTING_make_trait_reserve_priv (0,
reserve_priv),
+ TALER_TESTING_make_trait_reserve_pub (0,
+ reserve_pub),
TALER_TESTING_make_trait_amount_obj (0,
&ws->amount),
TALER_TESTING_make_trait_url (0, ws->exchange_url),