[tor-commits] [tor/master] rand: Clarify the crypto_rand_uint() range
teor at torproject.org
teor at torproject.org
Wed Apr 29 11:52:07 UTC 2020
commit 6eec43161ad9e072d82da88163e748566b39d127
Author: teor <teor at torproject.org>
Date: Wed Apr 29 15:57:44 2020 +1000
rand: Clarify the crypto_rand_uint() range
---
src/lib/crypt_ops/crypto_rand_numeric.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/lib/crypt_ops/crypto_rand_numeric.c b/src/lib/crypt_ops/crypto_rand_numeric.c
index ffbfa2d56..b2516c4bd 100644
--- a/src/lib/crypt_ops/crypto_rand_numeric.c
+++ b/src/lib/crypt_ops/crypto_rand_numeric.c
@@ -33,8 +33,8 @@
/**
* Return a pseudorandom integer chosen uniformly from the values between 0
- * and <b>limit</b>-1 inclusive. limit must be strictly between 0 and
- * UINT_MAX. */
+ * and <b>limit</b>-1 inclusive. limit must be strictly greater than 0, and
+ * less than UINT_MAX. */
unsigned
crypto_rand_uint(unsigned limit)
{
More information about the tor-commits
mailing list