Commit bf52911d authored by Niels Möller's avatar Niels Möller

Fixed scratch allocation in test_ecc_mul_h.

parent a3328c58
2014-09-23 Niels Möller <nisse@lysator.liu.se>
* testsuite/testutils.c (test_ecc_mul_h): Use ecc->h_to_a_itch.
* ecc-mod-inv.c (ecc_mod_inv): Interface change, make ap input
const, and require 2n limbs at rp. Preparing for powm-based
alternative implementations. Drop #if:ed out code and dp
......
......@@ -1436,7 +1436,7 @@ test_ecc_mul_h (unsigned curve, unsigned n, const mp_limb_t *p)
{
const struct ecc_curve *ecc = ecc_curves[curve];
mp_limb_t *np = xalloc_limbs (ecc_size_a (ecc));
mp_limb_t *scratch = xalloc_limbs (ecc_j_to_a_itch(ecc));
mp_limb_t *scratch = xalloc_limbs (ecc->h_to_a_itch);
ecc->h_to_a (ecc, 0, np, p, scratch);
test_ecc_mul_a (curve, n, np);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment