diff options
author | Marcello Stanisci <stanisci.m@gmail.com> | 2018-12-19 11:43:05 +0100 |
---|---|---|
committer | Marcello Stanisci <stanisci.m@gmail.com> | 2018-12-19 11:43:05 +0100 |
commit | 9c82290a1a472008f646a00a1ae802476188783c (patch) | |
tree | b7219b342384e16bb29fb7ebb505a48ae2836dd0 /src/exchange-lib/testing_api_cmd_payback.c | |
parent | b22b36a20bef3ad4b55e78a18fdedff15c1e5b54 (diff) |
#5459
Diffstat (limited to 'src/exchange-lib/testing_api_cmd_payback.c')
-rw-r--r-- | src/exchange-lib/testing_api_cmd_payback.c | 24 |
1 files changed, 13 insertions, 11 deletions
diff --git a/src/exchange-lib/testing_api_cmd_payback.c b/src/exchange-lib/testing_api_cmd_payback.c index 28792794..a4a3aeff 100644 --- a/src/exchange-lib/testing_api_cmd_payback.c +++ b/src/exchange-lib/testing_api_cmd_payback.c @@ -444,17 +444,18 @@ TALER_TESTING_cmd_payback (const char *label, const char *amount) { struct PaybackState *ps; - struct TALER_TESTING_Command cmd; ps = GNUNET_new (struct PaybackState); ps->expected_response_code = expected_response_code; ps->coin_reference = coin_reference; ps->amount = amount; - cmd.cls = ps; - cmd.label = label; - cmd.run = &payback_run; - cmd.cleanup = &payback_cleanup; + struct TALER_TESTING_Command cmd = { + .cls = ps, + .label = label, + .run = &payback_run, + .cleanup = &payback_cleanup + }; return cmd; } @@ -479,18 +480,19 @@ TALER_TESTING_cmd_revoke (const char *label, { struct RevokeState *rs; - struct TALER_TESTING_Command cmd; rs = GNUNET_new (struct RevokeState); rs->expected_response_code = expected_response_code; rs->coin_reference = coin_reference; rs->config_filename = config_filename; - cmd.cls = rs; - cmd.label = label; - cmd.run = &revoke_run; - cmd.cleanup = &revoke_cleanup; - cmd.traits = &revoke_traits; + struct TALER_TESTING_Command cmd = { + .cls = rs, + .label = label, + .run = &revoke_run, + .cleanup = &revoke_cleanup, + .traits = &revoke_traits + }; return cmd; } |