public inbox for newlib-cvs@sourceware.org
help / color / mirror / Atom feed
* [newlib-cygwin] stdlib/arc4random.c: Fix reseed count for 16-bit targets.
@ 2018-09-06 11:28 Corinna Vinschen
0 siblings, 0 replies; only message in thread
From: Corinna Vinschen @ 2018-09-06 11:28 UTC (permalink / raw)
To: newlib-cvs
https://sourceware.org/git/gitweb.cgi?p=newlib-cygwin.git;h=7283d2513c19618785d983e254005b9d36c7068e
commit 7283d2513c19618785d983e254005b9d36c7068e
Author: Jon Beniston <jon@beniston.com>
Date: Wed Sep 5 10:57:33 2018 +0100
stdlib/arc4random.c: Fix reseed count for 16-bit targets.
Diff:
---
newlib/libc/stdlib/arc4random.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/newlib/libc/stdlib/arc4random.c b/newlib/libc/stdlib/arc4random.c
index 3cccc3e..7632de1 100644
--- a/newlib/libc/stdlib/arc4random.c
+++ b/newlib/libc/stdlib/arc4random.c
@@ -99,7 +99,7 @@ _rs_stir(void)
rs->rs_have = 0;
memset(rsx->rs_buf, 0, sizeof(rsx->rs_buf));
- rs->rs_count = 1600000;
+ rs->rs_count = (SIZE_MAX <= 65535) ? 65000 : 1600000;
}
static inline void
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2018-09-06 11:28 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-09-06 11:28 [newlib-cygwin] stdlib/arc4random.c: Fix reseed count for 16-bit targets Corinna Vinschen
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).