aboutsummaryrefslogtreecommitdiff
path: root/src/testing/testing_api_cmd_keyshare_lookup.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/testing/testing_api_cmd_keyshare_lookup.c')
-rw-r--r--src/testing/testing_api_cmd_keyshare_lookup.c21
1 files changed, 11 insertions, 10 deletions
diff --git a/src/testing/testing_api_cmd_keyshare_lookup.c b/src/testing/testing_api_cmd_keyshare_lookup.c
index 5b2adea..8b06a67 100644
--- a/src/testing/testing_api_cmd_keyshare_lookup.c
+++ b/src/testing/testing_api_cmd_keyshare_lookup.c
@@ -222,7 +222,7 @@ keyshare_lookup_run (void *cls,
222 const struct ANASTASIS_CRYPTO_TruthKeyP *truth_key; 222 const struct ANASTASIS_CRYPTO_TruthKeyP *truth_key;
223 const struct ANASTASIS_CRYPTO_TruthUUIDP *truth_uuid; 223 const struct ANASTASIS_CRYPTO_TruthUUIDP *truth_uuid;
224 const struct ANASTASIS_PaymentSecretP *payment_secret; 224 const struct ANASTASIS_PaymentSecretP *payment_secret;
225 const char **answer; 225 const char **answerp;
226 226
227 ksls->is = is; 227 ksls->is = is;
228 if (NULL == ksls->upload_reference) 228 if (NULL == ksls->upload_reference)
@@ -301,13 +301,13 @@ keyshare_lookup_run (void *cls,
301 } 301 }
302 if (GNUNET_OK != 302 if (GNUNET_OK !=
303 ANASTASIS_TESTING_get_trait_code (download_cmd, 303 ANASTASIS_TESTING_get_trait_code (download_cmd,
304 &answer)) 304 &answerp))
305 { 305 {
306 GNUNET_break (0); 306 GNUNET_break (0);
307 TALER_TESTING_interpreter_fail (ksls->is); 307 TALER_TESTING_interpreter_fail (ksls->is);
308 return; 308 return;
309 } 309 }
310 if (NULL == *answer) 310 if (NULL == *answerp)
311 { 311 {
312 GNUNET_break (0); 312 GNUNET_break (0);
313 TALER_TESTING_interpreter_fail (ksls->is); 313 TALER_TESTING_interpreter_fail (ksls->is);
@@ -317,7 +317,7 @@ keyshare_lookup_run (void *cls,
317 else 317 else
318 { 318 {
319 /* answer is the answer */ 319 /* answer is the answer */
320 answer = &ksls->answer; 320 answerp = &ksls->answer;
321 } 321 }
322 322
323 if (NULL != ksls->payment_reference) 323 if (NULL != ksls->payment_reference)
@@ -344,9 +344,9 @@ keyshare_lookup_run (void *cls,
344 { 344 {
345 struct GNUNET_HashCode h_answer; 345 struct GNUNET_HashCode h_answer;
346 346
347 if (NULL != *answer) 347 if (NULL != *answerp)
348 GNUNET_CRYPTO_hash (*answer, 348 GNUNET_CRYPTO_hash (*answerp,
349 strlen (*answer), 349 strlen (*answerp),
350 &h_answer); 350 &h_answer);
351 ksls->kslo = ANASTASIS_keyshare_lookup (is->ctx, 351 ksls->kslo = ANASTASIS_keyshare_lookup (is->ctx,
352 ksls->anastasis_url, 352 ksls->anastasis_url,
@@ -354,7 +354,7 @@ keyshare_lookup_run (void *cls,
354 truth_key, 354 truth_key,
355 payment_secret, 355 payment_secret,
356 GNUNET_TIME_UNIT_ZERO, 356 GNUNET_TIME_UNIT_ZERO,
357 (NULL != *answer) 357 (NULL != *answerp)
358 ? &h_answer 358 ? &h_answer
359 : NULL, 359 : NULL,
360 &keyshare_lookup_cb, 360 &keyshare_lookup_cb,
@@ -386,6 +386,7 @@ keyshare_lookup_cleanup (void *cls,
386 GNUNET_free (ksls->pay_uri); 386 GNUNET_free (ksls->pay_uri);
387 GNUNET_free (ksls->order_id); 387 GNUNET_free (ksls->order_id);
388 GNUNET_free (ksls->code); 388 GNUNET_free (ksls->code);
389 GNUNET_free (ksls->filename);
389 GNUNET_free (ksls->instructions); 390 GNUNET_free (ksls->instructions);
390 GNUNET_free (ksls->redirect_uri); 391 GNUNET_free (ksls->redirect_uri);
391 GNUNET_free (ksls); 392 GNUNET_free (ksls);
@@ -401,7 +402,7 @@ keyshare_lookup_cleanup (void *cls,
401 * @param index index number of the object to extract. 402 * @param index index number of the object to extract.
402 * @return #GNUNET_OK on success 403 * @return #GNUNET_OK on success
403 */ 404 */
404static int 405static enum GNUNET_GenericReturnValue
405keyshare_lookup_traits (void *cls, 406keyshare_lookup_traits (void *cls,
406 const void **ret, 407 const void **ret,
407 const char *trait, 408 const char *trait,
@@ -416,7 +417,7 @@ keyshare_lookup_traits (void *cls,
416 TALER_TESTING_make_trait_order_id ( 417 TALER_TESTING_make_trait_order_id (
417 (const char **) &ksls->order_id), 418 (const char **) &ksls->order_id),
418 ANASTASIS_TESTING_make_trait_code ( 419 ANASTASIS_TESTING_make_trait_code (
419 (const char **) ksls->code), 420 (const char **) &ksls->code),
420 TALER_TESTING_trait_end () 421 TALER_TESTING_trait_end ()
421 }; 422 };
422 423