Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F140589334
D23199.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
452 B
Referenced Files
None
Subscribers
None
D23199.diff
View Options
Index: head/usr.bin/random/randomize_fd.c
===================================================================
--- head/usr.bin/random/randomize_fd.c
+++ head/usr.bin/random/randomize_fd.c
@@ -211,7 +211,7 @@
free(buf);
for (i = numnode; i > 0; i--) {
- selected = arc4random_uniform(numnode + 1);
+ selected = arc4random_uniform(numnode);
for (j = 0, prev = n = rand_root; n != NULL; j++, prev = n, n = n->next) {
if (j == selected) {
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Fri, Dec 26, 4:07 PM (4 h, 32 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
27285216
Default Alt Text
D23199.diff (452 B)
Attached To
Mode
D23199: random(6): Fix off-by-one error
Attached
Detach File
Event Timeline
Log In to Comment