summaryrefslogtreecommitdiff
path: root/bignum.c
diff options
context:
space:
mode:
authorNiels Möller <nisse@lysator.liu.se>2002-11-16 00:29:56 +0100
committerNiels Möller <nisse@lysator.liu.se>2002-11-16 00:29:56 +0100
commitd4a9b46ddb38e2b9fb9d05146f8580f7643cdf40 (patch)
tree32aff5d1458f2c0bad641c597595e6d592a003e7 /bignum.c
parent8aeecc155d3aef5dae8762ace236dd6365fb636d (diff)
downloadnettle-d4a9b46ddb38e2b9fb9d05146f8580f7643cdf40.tar.gz
Added FIXME to nettle_mpz_get_str_256.
Rev: src/nettle/bignum.c:1.6
Diffstat (limited to 'bignum.c')
-rw-r--r--bignum.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/bignum.c b/bignum.c
index d923d702..59bca94e 100644
--- a/bignum.c
+++ b/bignum.c
@@ -119,7 +119,10 @@ nettle_mpz_get_str_256(unsigned length, uint8_t *s, const mpz_t x)
mpz_t c;
mpz_init(c);
mpz_com(c, x);
-
+
+ /* FIXME: A different trick is to complement all the limbs of c
+ * now. That way, nettle_mpz_to_octets need not complement each
+ * digit. */
assert(nettle_mpz_sizeinbase_256_u(c) <= length);
nettle_mpz_to_octets(length, s, c, 0xff);