diff options
author | Christian Grothoff <christian@grothoff.org> | 2017-05-07 14:07:48 +0200 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2017-05-07 14:07:48 +0200 |
commit | 0e73c0d4513a360ba3b5bcbe70ef4aeb59f68e3c (patch) | |
tree | 0887e31dabaeef49eb2ebd50a1caed9e765b597f /src/exchange-lib/exchange_api_payback.c | |
parent | 76545519c647b66ef99391b503f5d90fd4a43cb4 (diff) | |
download | exchange-0e73c0d4513a360ba3b5bcbe70ef4aeb59f68e3c.tar.xz |
check json_pack return value, just to be nice
Diffstat (limited to 'src/exchange-lib/exchange_api_payback.c')
-rw-r--r-- | src/exchange-lib/exchange_api_payback.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/exchange-lib/exchange_api_payback.c b/src/exchange-lib/exchange_api_payback.c index 30cd55cba..8096e55f8 100644 --- a/src/exchange-lib/exchange_api_payback.c +++ b/src/exchange-lib/exchange_api_payback.c @@ -57,7 +57,7 @@ struct TALER_EXCHANGE_PaybackHandle * Denomination key of the coin. */ const struct TALER_EXCHANGE_DenomPublicKey *pk; - + /** * Handle for the request. */ @@ -306,7 +306,11 @@ TALER_EXCHANGE_payback (struct TALER_EXCHANGE_Handle *exchange, "coin_sig", GNUNET_JSON_from_data_auto (&coin_sig), "coin_blind_key_secret", GNUNET_JSON_from_data_auto (blinding_key) ); - GNUNET_assert (NULL != payback_obj); + if (NULL == payback_obj) + { + GNUNET_break (0); + return NULL; + } ph = GNUNET_new (struct TALER_EXCHANGE_PaybackHandle); ph->coin_pub = pr.coin_pub; |