pike.git/
src/
builtin.cmod
Branch:
Tag:
Non-build tags
All tags
No tags
2016-03-29
2016-03-29 06:26:51 by Martin Nilsson <nilsson@fastmail.com>
4343cee3cc1501d7a9b7d9b52864b2c47b905508 (
5
lines) (+
5
/-
0
)
[
Show
|
Annotate
]
Branch:
8.1
Comment on the soundness of the bitstring to integer conversion.
2112:
pop_stack(); }
+
/* Generates a number 0<=c<limit from random bits taken from the
+
int_buffer. Follows the NIST SP800-90A method for converting bit
+
sequences into bound numbers, described in section B.5.1.1, and
+
summarized as "throw away attempts that are too large". */
static INT_TYPE read_int(INT_TYPE limit) { if(limit <= 1) return 0;