diff options
author | Christian Grothoff <christian@grothoff.org> | 2019-09-15 12:39:15 +0200 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2019-09-15 12:39:15 +0200 |
commit | ebd2e7d763689430d37386903ac190da4943ce2c (patch) | |
tree | 52e62b3005e39923590b300dfa04a37fb88354a0 /src/lib | |
parent | a3d272eb9d1fdb130e98fc9d67198106a2aef53d (diff) |
fix leaks and unnecessary fetch of RSA signature on refresh/reveal
Diffstat (limited to 'src/lib')
-rw-r--r-- | src/lib/exchange_api_handle.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/lib/exchange_api_handle.c b/src/lib/exchange_api_handle.c index 80a07318b..8e523e3b4 100644 --- a/src/lib/exchange_api_handle.c +++ b/src/lib/exchange_api_handle.c @@ -1024,7 +1024,12 @@ decode_keys_json (const json_t *resp_obj, } } if (GNUNET_YES == found) + { + GNUNET_array_grow (ai.denom_keys, + ai.num_denom_keys, + 0); continue; /* we are done */ + } if (key_data->auditors_size == key_data->num_auditors) GNUNET_array_grow (key_data->auditors, key_data->auditors_size, @@ -1564,11 +1569,15 @@ deserialize_data (struct TALER_EXCHANGE_Handle *exchange, return; } if (0 != version) + { + GNUNET_JSON_parse_free (spec); return; /* unsupported version */ + } if (0 != strcmp (url, exchange->url)) { GNUNET_break (0); + GNUNET_JSON_parse_free (spec); return; } memset (&key_data, @@ -1581,6 +1590,7 @@ deserialize_data (struct TALER_EXCHANGE_Handle *exchange, &vc)) { GNUNET_break (0); + GNUNET_JSON_parse_free (spec); return; } /* decode successful, initialize with the result */ @@ -1594,6 +1604,7 @@ deserialize_data (struct TALER_EXCHANGE_Handle *exchange, exchange->cert_cb (exchange->cert_cb_cls, &exchange->key_data, vc); + GNUNET_JSON_parse_free (spec); } |